React
TheGuidesHeadlines widget lets you reference and render different guides on your website.
Installation
The Algolia Guides React package is available on the npm registry.Usage
React
Parameters
The initialized Algolia Generative Experiences client.
The category used for retrieving the headlines.
The number of headlines to display (between 1 and 1000).
Whether to only return headlines with generated content.
Whether to generate and display the headlines on load.
Whether to show the feedback widget.
If true, you also need to provide a
userToken.The user token needed for computing feedback.
Required if
showFeedback is true.Search parameters that are applied when fetching headlines. Can be used for pagination or custom filtering.Not all search parameters are supported. Some parameters are ignored to ensure the correct functioning of the widget:
facetFilters, hitsPerPage, optionalFilters, attributesToHighlight and getRankingInfo.For more information, see API parameters.A render function to fully customize what’s displayed.The default implementation is:
React
The view component into which your guide headlines will be rendered.The default implementation is:
React
Component to display the headlines.
The class names for the component.
TypeScript
JavaScript
TheguidesHeadlines widget lets you reference and render different guides on your website.
Installation
The Algolia Guides JavaScript package is available on the npm registry.Usage
JavaScript
Parameters
The initialized Algolia Generative Experiences client.
The category used for retrieving the headlines.
The number of headlines to display (between 1 and 1000).
Whether to only return headlines with generated content.
Whether to generate and display the headlines on load.
Whether to show the feedback widget.
If true, you also need to provide a
userToken.The user token needed for computing feedback.
Required if
showFeedback is true.A render function to fully customize what’s displayed.The default implementation is:
JavaScript
The view component into which your guide headlines will be rendered.The default implementation is:
JavaScript
Component to display the headlines.
The class names for the component.
TypeScript