test algolia search
This commit is contained in:
18
components/docsearch.tsx
Normal file
18
components/docsearch.tsx
Normal file
@@ -0,0 +1,18 @@
|
||||
'use client'
|
||||
// sample code from https://docsearch.algolia.com/docs/docsearch
|
||||
|
||||
import { DocSearch } from '@docsearch/react';
|
||||
|
||||
import '@docsearch/css';
|
||||
|
||||
function AlgoliaSearch() {
|
||||
return (
|
||||
<DocSearch
|
||||
appId={process.env.NEXT_SEARCH_ALGOLIA_APP_ID || ''}
|
||||
indexName={process.env.NEXT_SEARCH_ALGOLIA_INDEX_NAME || ''}
|
||||
apiKey={process.env.NEXT_SEARCH_ALGOLIA_API_KEY || ''}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
export default AlgoliaSearch;
|
||||
Reference in New Issue
Block a user