docusaurus-search-local icon indicating copy to clipboard operation
docusaurus-search-local copied to clipboard

Support Docusaurus 2.0 stable

Open Fannon opened this issue 3 years ago • 1 comments

Docusaurus 2 is out 🎆 ! https://docusaurus.io/blog/2022/08/01/announcing-docusaurus-2.0

The current version of this plugin still has an outdated peer dependency:

npm ERR! Conflicting peer dependency: @docusaurus/[email protected]
npm ERR! node_modules/@docusaurus/core
npm ERR!   peer @docusaurus/core@"^v2.0.0-beta.21" from @cmfcmf/[email protected]
npm ERR!   node_modules/@cmfcmf/docusaurus-search-local
npm ERR!     @cmfcmf/docusaurus-search-local@"0.11.0" from the root project

It can be force installed via

npm i --legacy-peer-deps

But when trying this quicky, I'm not sure if it worked, the search index couldn't be found even after running a build. So maybe some additional work needs to be done to get it on 2.0 officially.

Thanks for working on this plugin, it's really helpful!

Fannon avatar Aug 04 '22 15:08 Fannon

In docusaurus v2.1.0 the search bar doesn't display even when having this navbar item:

        {
          type: 'search',
          position: 'right',
        }

noraj avatar Sep 03 '22 19:09 noraj

I finally added support for Docusaurus v2 in https://github.com/cmfcmf/docusaurus-search-local/commit/f8619b72ec748ac084b53cf7c88157419a27863a.

cmfcmf avatar Dec 22 '22 17:12 cmfcmf