mirror of
https://github.com/facebook/docusaurus.git
synced 2025-06-06 21:03:47 +02:00
docs(v2): config for self-hosted docsearch crawler (#4524)
This commit is contained in:
parent
b9de28e42f
commit
11843a02fe
1 changed files with 21 additions and 0 deletions
|
@ -33,6 +33,9 @@ module.exports = {
|
||||||
// Optional: see doc section below
|
// Optional: see doc section below
|
||||||
contextualSearch: true,
|
contextualSearch: true,
|
||||||
|
|
||||||
|
// Optional: see doc section below
|
||||||
|
appId: 'YOUR_APP_ID',
|
||||||
|
|
||||||
// Optional: Algolia search parameters
|
// Optional: Algolia search parameters
|
||||||
searchParameters: {},
|
searchParameters: {},
|
||||||
|
|
||||||
|
@ -80,6 +83,24 @@ When using `contextualSearch: true`, the contextual facet filters will be merged
|
||||||
|
|
||||||
:::
|
:::
|
||||||
|
|
||||||
|
### Custom Application ID {#custom-application-id}
|
||||||
|
|
||||||
|
When [running your own](https://docsearch.algolia.com/docs/run-your-own/) DocSearch crawler, it is [required to set the `appId` configuration key](https://docsearch.algolia.com/docs/behavior/#appid) to your own Application ID. If left unset, the `appId` will fallback to the one used with the free, hosted version of Algolia DocSearch.
|
||||||
|
|
||||||
|
```jsx title="docusaurus.config.js"
|
||||||
|
module.exports = {
|
||||||
|
// ...
|
||||||
|
themeConfig: {
|
||||||
|
// ...
|
||||||
|
// highlight-start
|
||||||
|
algolia: {
|
||||||
|
appId: 'YOUR_APP_ID',
|
||||||
|
},
|
||||||
|
// highlight-end
|
||||||
|
},
|
||||||
|
};
|
||||||
|
```
|
||||||
|
|
||||||
### Styling your Algolia search {#styling-your-algolia-search}
|
### Styling your Algolia search {#styling-your-algolia-search}
|
||||||
|
|
||||||
By default, DocSearch comes with a fine-tuned theme that was designed for accessibility, making sure that colors and contrasts respect standards.
|
By default, DocSearch comes with a fine-tuned theme that was designed for accessibility, making sure that colors and contrasts respect standards.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue