For the complete documentation index, see llms.txt. This page is also available as Markdown.

Similar Products

Display products similar to selected records through the Similar Products API.

Documentation

Overview

Use ff-similar-products to display a record list of products similar to another product.

Use an ff-record-list inside the element. ff-similar-products injects records returned by the Similar Products API.

<ff-similar-products>
    <div class="similarProductsHeader">Similar Products</div>

    <ff-record-list>
        <ff-record>
            <img data-image>
            <div>
                <a href="https://www.bergfreunde.de/{{record.Deeplink}}" data-action="redirect">
                    {{record.Title}}
                </a>
                <div>Price: <strong>{{record.Price}} €</strong></div>
            </div>
        </ff-record>
    </ff-record-list>
</ff-similar-products>

Attributes

record-id

Set record-id to request similar products for that record.

max-results

max-results defines how many records load. It defaults to 4.

Demo

API code

Properties

(* - required, † - conditionally required)

Properties
Name
Description

record-id* (Number)

The record ID of the product, for which similar products are returned. This also works for multiple products. In this case the record IDs have to be separated with ,.

id-type† (String) Options: "id", "productNumber"

This attribute determines the type of record-id. It is mandatory when using FactFinder NG.

max-results (Number) (default: 4)

The maximum amount of returned similar products.

Methods

Methods
Name
Description

getSimilarProducts()

Calls up the similar products again.

Last updated

Was this helpful?