Skip to main content

React

The GuideContent widget lets you render the content of a guide on your website.

Installation

The Algolia Guides React package is available on the npm registry.

Usage

React

Parameters

client
GSEClient
required
The initialized Algolia Generative Experiences client.
objectID
string
required
The ID of the guide to be retrieved.
itemComponent
({ item, createElement, Fragment, html }) => JSX.Element | VNode | VNode[]
required
Component to display the items featured in the guide.
onlyPublished
boolean
default:true
Whether to only return headlines with generated content.
showImmediate
boolean
default:true
Whether to generate and display the headlines on load.
The title of the related items carousel found at the end of a guide. Default: Items featured in this article
The number of featured items displayed at the end of a guide.
showFeedback
boolean
default:false
Whether to show the feedback widget. If true, you also need to provide a userToken.
userToken
string
The user token needed for computing feedback. Required if showFeedback is true.
children
(props: ChildrenProps) => JSX.Element
A render function to fully customize what’s displayed.The default implementation is:
React
view
ViewProps
The view component into which your guide content will be rendered.
classNames
ContentClassNames
The class names for the component.
TypeScript

JavaScript

The guideContent 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

client
GSEClient
required
The initialized Algolia Generative Experiences client.
objectID
string
required
The ID for the guide to be retrieved.
itemComponent
({ item, createElement, Fragment, html }) => JSX.Element | VNode | VNode[]
required
Component to display the items featured in the guide.
onlyPublished
boolean
default:true
Whether to only return headlines with generated content.
showImmediate
boolean
default:true
Whether to generate and display the headlines on load.
The title of the related items carousel found at the end of a guide. Default: Items featured in this article
The number of featured items displayed at the end of a guide.
showFeedback
boolean
default:false
Whether to show the feedback widget. If true, you also need to provide a userToken.
userToken
string
The user token needed for computing feedback. Required if showFeedback is true
children
(props: ChildrenProps) => JSX.Element
A render function to fully customize what’s displayed.The default implementation is:
JavaScript
view
ViewProps
The view component into which your guide content will be rendered.
classNames
ContentClassNames
The Class names for the component.
TypeScript
Last modified on May 19, 2026