Render Search Results on the Client Side

The lazy tag library is a collection of JSP tags for rendering search results on the client-side. These tags are commonly used, for example, when loading a secondary result set that can be displayed separately from the main search results.

Usage

To use this library, you must include a reference to the Labs module in your Maven project’s pom.xml file:

<dependency>
    <groupId>twigkit</groupId>
    <artifactId>twigkit.web.components.lab</artifactId>
    <version>${project.parent.version}</version>
</dependency>

Example

This example shows how to query a search platform through a client-side request (identified by the platforms.example configuration):

<lazy:resultList conf="platforms.example" query="${myQuery}">
    <lazy:result>
        <lazy:field fieldName="title" style="title" />
        <lazy:field fieldName="address" suffix=" USA" />
    </lazy:result>
</lazy:resultList>