> For the complete documentation index, see [llms.txt](https://docs.fact-finder.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fact-finder.com/webcomponents-overview/web-components-4.x./api/basic-elements/record-list.md).

# Record List

Render product records with templates, redirects, and click tracking.

## Documentation

## API reference

**`ff-record-list`**

<details>

<summary>Properties</summary>

| Property                                 | Description                              |
| ---------------------------------------- | ---------------------------------------- |
| **subscribe** (String, default `"true"`) | Set `"false"` to dispatch your own data. |
| **records** (Array)                      | Record objects returned by FactFinder.   |
| **ssr** (Boolean)                        | Enables SSR mode.                        |

</details>

<details>

<summary>Events and methods</summary>

| Event or method    | Description                                |
| ------------------ | ------------------------------------------ |
| **loadNextPage()** | Loads the next page.                       |
| **dom-updated**    | Fires after new data and templates render. |

</details>

**`ff-record`**

<details>

<summary>Properties</summary>

| Property                                              | Description                      |
| ----------------------------------------------------- | -------------------------------- |
| **record-data** (Object)                              | Record returned by FactFinder.   |
| **add-cart-click** / **add-checkout-click** (Boolean) | Enables tracking for that click. |

</details>

<details>

<summary>Directives</summary>

| Directive                                    | Description                                            |
| -------------------------------------------- | ------------------------------------------------------ |
| **data-redirect** / **data-redirect-target** | Redirects to a product page and configures its target. |
| **data-track**                               | Sends tracking on click.                               |
| **data-image** / **data-anchor**             | Binds an image `src` or anchor `href`.                 |
| **disable-overwrite**                        | Restores normal anchor behavior without tracking.      |

</details>

### Overview

Use the `ff-record` and `ff-record-list` elements to design a template for each record. Access record data, such as name, price, and rating, with Mustache syntax: `{{record.xxx}}`. The available values are defined in the FactFinder backend. They match the field names from the imported feed.

### Adding images

Use the `data-image` attribute to display an image. Set its value to the data binding for the image URL field. This example uses the `ImageName` field.

Add `data-image-onerror` to specify an error image. It displays when the image URL cannot be loaded.

```html
<ff-record-list>
  <ff-record>
    <img
      data-image="{{record.ImageName}}"
      data-image-onerror="https://shop123.com/error.png"
    >
    <span>{{record.Title}}</span>
  </ff-record>
</ff-record-list>
```

### Redirecting to a product page

Use `data-redirect` for product redirects. This attribute also sends the tracking request.

Set `data-redirect-target` to any HTML-compliant target value: `_blank`, `_self`, `_parent`, `_top`, or a frame name.

```html
<ff-record-list>
  <ff-record>
    <div
      data-redirect="{{record.Deeplink}}"
      data-redirect-target="_blank"
    >
      <img data-image="{{record.ImageName}}">
      <span>{{record.Title}}</span>
    </div>
  </ff-record>
</ff-record-list>
```

### Adding links

Use `data-anchor` rather than `href` to add product links. It sets the `href` attribute from the record data.

Normal `href` behavior is disabled by default. Add `disable-overwrite` to `ff-record` to restore it.

{% hint style="warning" %}
`disable-overwrite` disables automatic tracking.
{% endhint %}

```html
<ff-record-list>
  <ff-record disable-overwrite>
    <div>
      <a
        data-redirect="{{record.Deeplink}}"
        data-redirect-target="_blank"
        data-anchor="https://www.myshop.de{{record.Deeplink}}"
      >
        Shop
      </a>

      <img data-image="{{record.ImageName}}">
      <span>{{record.Title}}</span>
    </div>
  </ff-record>
</ff-record-list>
```

### Adding tracking

Use `data-track` to send tracking requests from `ff-record`. This is useful when you want to track a click without redirecting the user.

```html
<ff-record-list>
  <ff-record>
    <div data-track>Don't redirect, but track.</div>

    <div
      data-redirect="{{record.Deeplink}}"
      data-redirect-target="_blank"
    >
      <img data-image="{{record.ImageName}}">
      <span>{{record.Title}}</span>
    </div>
  </ff-record>
</ff-record-list>
```

### Cart and checkout tracking

Add `add-cart-click`, `add-checkout-click`, or both to `ff-record`. Use `data-track="cartClick"` or `data-track="checkoutClick"` on any descendant element.

```html
<ff-record-list>
  <ff-record add-cart-click add-checkout-click>
    <div data-track="cartClick">Track a cart click without redirecting.</div>
    <div data-track="checkoutClick">Track a one-click checkout.</div>

    <div
      data-redirect="{{record.Deeplink}}"
      data-redirect-target="_blank"
    >
      <img data-image="{{record.ImageName}}">
      <span>{{record.Title}}</span>
    </div>
  </ff-record>
</ff-record-list>
```

Add `data-track-count` to read the number of products being added or checked out. Set its value to the element property that holds the count, such as `textContent`, `innerHTML`, or `value`.

Without a value, `data-track-count` reads the element's `value` property. If no value exists, it defaults to `1`.

```html
<ff-record-list>
  <ff-record add-cart-click add-checkout-click>
    <div data-track="cartClick">Track a cart click without redirecting.</div>
    <div data-track="checkoutClick">Track a one-click checkout.</div>

    <!-- Read the count from textContent. -->
    <div data-track-count="textContent">2</div>

    <!-- Or read the default value property. -->
    <input data-track-count type="number" value="2">
  </ff-record>
</ff-record-list>
```

### Server-side rendering

Enable server-side rendering with the `ssr` attribute.

```html
<ff-record-list ssr>
  ...
</ff-record-list>
```

For integration details, see [Server Side Rendering](/webcomponents-overview/web-components-4.x./guides/advanced/server-side-rendering.md).

## Demo

Try the [Record List demo](https://search-web-components.fact-finder.de/demos/4.x/ff-record-list).

## API code

### `ff-record-list`

**Properties**

<details>

<summary>Properties</summary>

| Name                                      | Description                                     |
| ----------------------------------------- | ----------------------------------------------- |
| **subscribe** (String, default: `"true"`) | Set `"false"` to dispatch your own record data. |
| **records** (Array)                       | Record data returned by FactFinder.             |
| **ssr** (Boolean)                         | Enables server-side rendering mode.             |

</details>

**Methods**

<details>

<summary>Methods</summary>

| Name               | Description          |
| ------------------ | -------------------- |
| **loadNextPage()** | Loads the next page. |

</details>

**Events**

<details>

<summary>Events</summary>

| Name            | Description                                |
| --------------- | ------------------------------------------ |
| **dom-updated** | Fires after new data and templates render. |

</details>

### `ff-record`

**Properties**

<details>

<summary>Properties</summary>

| Name                             | Description                           |
| -------------------------------- | ------------------------------------- |
| **record-data** (Object)         | Record object returned by FactFinder. |
| **add-cart-click** (Boolean)     | Enables cart-click tracking.          |
| **add-checkout-click** (Boolean) | Enables checkout-click tracking.      |

</details>

**Directives**

<details>

<summary>Directives</summary>

| Name                     | Description                                               |
| ------------------------ | --------------------------------------------------------- |
| **data-redirect**        | Redirects to a product page when a valid URL is provided. |
| **data-redirect-target** | Configures the redirect target.                           |
| **data-track**           | Sends a tracking request when clicked.                    |
| **data-image**           | Binds an image `src` from record data.                    |
| **data-anchor**          | Binds an anchor `href` from record data.                  |
| **disable-overwrite**    | Restores default anchor behavior without tracking.        |

</details>

####


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.fact-finder.com/webcomponents-overview/web-components-4.x./api/basic-elements/record-list.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
