feat: add search

This commit is contained in:
cupcakearmy 2023-02-19 14:31:20 +01:00
parent f0cea84471
commit 67aca792cf
No known key found for this signature in database
GPG Key ID: 3235314B4D31232F
3 changed files with 686 additions and 1009 deletions

View File

@ -20,6 +20,8 @@ const config = {
locales: ['en'], locales: ['en'],
}, },
themes: [[require.resolve('@easyops-cn/docusaurus-search-local'), { hashed: true }]],
presets: [ presets: [
[ [
'classic', 'classic',

View File

@ -1,6 +1,6 @@
{ {
"name": "docs", "name": "memoir",
"version": "0.0.0", "version": "1.0.0",
"private": true, "private": true,
"scripts": { "scripts": {
"docusaurus": "docusaurus", "docusaurus": "docusaurus",
@ -15,8 +15,8 @@
"typecheck": "tsc" "typecheck": "tsc"
}, },
"dependencies": { "dependencies": {
"@docusaurus/core": "2.3.0", "@docusaurus/core": "^2.3.1",
"@docusaurus/preset-classic": "2.3.0", "@docusaurus/preset-classic": "^2.3.1",
"@mdx-js/react": "^1.6.22", "@mdx-js/react": "^1.6.22",
"clsx": "^1.2.1", "clsx": "^1.2.1",
"prism-react-renderer": "^1.3.5", "prism-react-renderer": "^1.3.5",
@ -24,7 +24,9 @@
"react-dom": "^17.0.2" "react-dom": "^17.0.2"
}, },
"devDependencies": { "devDependencies": {
"@docusaurus/module-type-aliases": "2.3.0", "@docusaurus/module-type-aliases": "^2.3.1",
"@docusaurus/theme-common": "^2.3.1",
"@easyops-cn/docusaurus-search-local": "^0.34.0",
"@tsconfig/docusaurus": "^1.0.6", "@tsconfig/docusaurus": "^1.0.6",
"typescript": "^4.9.5" "typescript": "^4.9.5"
}, },

1681
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff