Can't get plugin-search to work #500
Answered
by
Mister-Hope
Oskar-Nilsen-Roos
asked this question in
Q&A
-
As the title says I can't get ⠋ Rendering pages⠋ Rendering pages /Error: useRouteLocale() is called without provider.
at useRouteLocale (C:\Projects\Wiki\docs\.vuepress\dist\.server\app.js:1022:11)
at setup (C:\Projects\Wiki\docs\.vuepress\dist\.server\app.js:1534:25)
at callWithErrorHandling (C:\Projects\Wiki\node_modules\@vue\runtime-core\dist\runtime-core.cjs.prod.js:5361:22)
at setupStatefulComponent (C:\Projects\Wiki\node_modules\@vue\runtime-core\dist\runtime-core.cjs.prod.js:5077:29)
at setupComponent (C:\Projects\Wiki\node_modules\@vue\runtime-core\dist\runtime-core.cjs.prod.js:5058:11)
at renderComponentVNode (C:\Projects\Wiki\node_modules\@vue\server-renderer\dist\server-renderer.cjs.prod.js:195:17)
at renderVNode (C:\Projects\Wiki\node_modules\@vue\server-renderer\dist\server-renderer.cjs.prod.js:301:22)
at renderComponentSubTree (C:\Projects\Wiki\node_modules\@vue\server-renderer\dist\server-renderer.cjs.prod.js:218:9)
at renderComponentVNode (C:\Projects\Wiki\node_modules\@vue\server-renderer\dist\server-renderer.cjs.prod.js:211:16)
at renderVNode (C:\Projects\Wiki\node_modules\@vue\server-renderer\dist\server-renderer.cjs.prod.js:301:22)
[Vue warn]: Component SearchBox is missing template or render function. package.json {
"name": "..",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"docs:dev": "vuepress dev docs",
"docs:build": "vuepress build docs"
},
"author": "",
"license": "ISC",
"devDependencies": {
"@vuepress/bundler-vite": "^2.0.0-beta.26",
"@vuepress/cli": "2.0.0-alpha.26",
"vuepress-vite": "^2.0.0-beta.26"
},
"dependencies": {
"@vuepress/plugin-search": "^2.0.0-beta.26",
"vuepress": "^2.0.0-beta.26"
}
}
config.ts import type { ViteBundlerOptions } from '@vuepress/bundler-vite'
import type {
DefaultThemeOptions,
SidebarConfig
} from '@vuepress/theme-default'
const sidebar: SidebarConfig = {
[..]
}
export default {
base: '/',
bundler: '@vuepress/vite',
bundlerConfig: {},
title: '..',
description: 'This is my first VuePress site',
smoothScroll: true,
themeConfig: {
..
},
plugins: [
[
'@vuepress/plugin-search',
{
// exclude the homepage
isSearchable: (page) => page.path !== '/',
},
],
],
} Is there something I've missed? Would greatly appreciate the help, thank you! |
Beta Was this translation helpful? Give feedback.
Answered by
Mister-Hope
Mar 1, 2022
Replies: 1 comment
-
Hi there, is the issue still exist in latest version? If so, open an issue with a mininal reproductin repo link. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
Mister-Hope
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi there, is the issue still exist in latest version? If so, open an issue with a mininal reproductin repo link.