Example
The following template shows an example with best fragment for each resource.
<script id="custom-result-item" type="x-template"> <div class="result-item"> <p class="result-item-title">{{ getField('title') }}</p> <p>{{ result.BestFragments.itemname }}</p> </div> </script>
Example in Sitefinity context. The following template should be used in \ResourcePackages\Bootstrap4\MVC\Views\Hawksearch\Hawksearch.Default.cshtml or any Sitefinity template.
<script id="vue-hawksearch-result-item" type="x-template"> <div class="media-body sf-media-body"> <h3> <template v-if="link"> <a :href=link>{{ title }}</a> </template> <template v-else> {{ title }} </template> </h3> <p> <span>{{ result.BestFragments.itemname }}</span> <span>{{ content }}</span> </p> <a :href="link">{{ link }}</a> </div> </script>