chore: use Babel to replace DocSearch verison in UA
This commit is contained in:
parent
07e606a00c
commit
c44360258d
2 changed files with 1 additions and 4 deletions
|
|
@ -1,12 +1,10 @@
|
|||
import React from 'react';
|
||||
import algoliasearch from 'algoliasearch/dist/algoliasearch-lite.esm.browser';
|
||||
|
||||
import { version } from './version';
|
||||
|
||||
export function useSearchClient(appId: string, apiKey: string) {
|
||||
const searchClient = React.useMemo(() => {
|
||||
const client = algoliasearch(appId, apiKey);
|
||||
client.addAlgoliaAgent(`docsearch (${version})`);
|
||||
client.addAlgoliaAgent(`docsearch (${__VERSION__})`);
|
||||
|
||||
return client;
|
||||
}, [appId, apiKey]);
|
||||
|
|
|
|||
|
|
@ -1 +0,0 @@
|
|||
export const version = '1.0.0-alpha.10';
|
||||
Loading…
Reference in a new issue