Hello! Is there any example or documentation for i...
# community-help
k
Hello! Is there any example or documentation for integrating typesense with markdown based next.js application? I am using nextra and need to somehow extract pages and create indexes
j
If you need to scrape rendered content, then you want to use the Docsearch scraper: https://typesense.org/docs/guide/docsearch.html
Besides that, the other way would be to push JSON data into Typesense via it's API directly
k
Thanks! ❤️
👍 1
@Jason Bosco Is there any guide on how to use typesense-docsearch-react? Or how to use docsearch.js in React/Next.js?
j
It's similar to the instructions here: https://www.npmjs.com/package/@docsearch/react But instead of these props:
Copy code
appId="YOUR_APP_ID"
indexName="YOUR_INDEX_NAME"
apiKey="YOUR_SEARCH_API_KEY"
You'd want to use these props instead: https://github.com/typesense/docusaurus-theme-search-typesense/blob/bc08886524a705148f275479a897531fbab611b8/src/theme/SearchBar/index.tsx#L242-L244
1
k
@Jason Bosco Hello! Wanted to ask if its possible to use instant search instead of docsearch for documentation? I saw it has some support functions to help render hits. As Im pretty much just sending a http request to typesense right now, and then render hits based on highlight field, because need a fully custom UI, doing it with https://cmdk.paco.me/
j
Yeah you can definitely use your own UI. Just need to make sure you group_by URL to prevent duplicates, just like what the docsearch UI does
❤️ 1