Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nothing appears, no debug logs, no search index file or errors #352

Open
alexgurr opened this issue Oct 31, 2023 · 3 comments
Open

Nothing appears, no debug logs, no search index file or errors #352

alexgurr opened this issue Oct 31, 2023 · 3 comments

Comments

@alexgurr
Copy link

alexgurr commented Oct 31, 2023

Added the following section to the docusaurus config file:

 themes: [
        [
          '@easyops-cn/docusaurus-search-local',
          /** @type {import("@easyops-cn/docusaurus-search-local").PluginOptions} */
          ({
            hashed: true,
            highlightSearchTermsOnTargetPage: true,
            explicitSearchResultPath: true
          })
        ]
      ]

I cannot get the search to appear, even when running npm run serve after a build. I get no debug logs, no output and no errors. Haven't been able to work out what's happening here.

Any ideas?

 "@docusaurus/core": "^2.4.3",
    "@docusaurus/preset-classic": "^2.4.3",
    "@easyops-cn/docusaurus-search-local": "^0.36.0",
Screenshot 2023-10-31 at 2 20 15 pm
@mlagergren
Copy link

mlagergren commented Jan 5, 2024

Same issue here, did you figure it out?

@mlagergren
Copy link

Same solution for me: #206

@juan-belmonte
Copy link

In my case, it was the noIndex: true setting in docusaurus.config.js causing the search-index.json file to be empty.

I just had to specify the forceIgnoreNoIndex: true setting in the @easyops-cn/docusaurus-search-local theme block.
Hope that helps someone spend less time than I did — it's probably beneficial to add a log message suggesting that change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants