shanyuhai123 / vuepress-plugin-auto-sidebar

vuepress 自动生成侧边栏的插件。
https://shanyuhai123.github.io/vuepress-plugin-auto-sidebar/
MIT License
138 stars 29 forks source link

build error: No matching page found for sidebar item "/implementation/Theme.TheAdmin/index" #58

Closed scil closed 2 years ago

scil commented 2 years ago

env:

    "vuepress": "^1.9.7",
    "vuepress-plugin-auto-sidebar": "^2.3.2"

files under dir ./docs/

README.md
│
└─implementation
    │  README.md
    │
    ├─Module.Common
    │  │  README.md
    │  │  words敏感词.md
    │  │
    │  └─CommentAdmin
    │          README.md
    │
    └─Theme.TheAdmin
        │  ArticleService.md
        │  index.md
        │
        └─ArticleAdmin
                edit.md
                index.md
D:\A\Scoop\apps\nodejs\current\node.exe D:\A\Scoop\apps\nodejs\current\node_modules\npm\bin\npm-cli.js run docs:build 

> docs:build
> vuepress build docs

√ Server
  Compiled successfully in 42.93s

√ Client
  Compiled successfully in 51.16s

√ Server
  Compiled successfully in 42.93s

Language does not exist: c#
wait Rendering static HTML...
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/index"
[Vue warn]: Error in render: "TypeError: Cannot read properties of undefined (reading 'match')"

found in

---> <SidebarLinks>
       <DropdownTransition>
         <SidebarGroup>
           <SidebarLinks>
             <Sidebar>
               <Layout>
                 <GlobalLayout>
                   <Root>
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/ArticleAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/ArticleAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/ArticleAdmin/index"
[Vue warn]: Error in render: "TypeError: Cannot read properties of undefined (reading 'match')"

found in

---> <SidebarLinks>
       <DropdownTransition>
         <SidebarGroup>
           <SidebarLinks>
             <Sidebar>
               <Layout>
                 <GlobalLayout>
                   <Root>
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/ArticleAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/ArticleAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/ArticleAdmin/index"
[Vue warn]: Error in render: "TypeError: Cannot read properties of undefined (reading 'match')"

found in

---> <SidebarLinks>
       <DropdownTransition>
         <SidebarGroup>
           <SidebarLinks>
             <Sidebar>
               <Layout>
                 <GlobalLayout>
                   <Root>
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/index"
[vuepress] No matching page found for sidebar item "/implementation/Theme.TheAdmin/index"
[Vue warn]: Error in render: "TypeError: Cannot read properties of undefined (reading 'match')"

found in

---> <SidebarLinks>
       <DropdownTransition>
         <SidebarGroup>
           <SidebarLinks>
             <Sidebar>
               <Layout>
                 <GlobalLayout>
                   <Root>
error Error rendering /implementation/Theme.TheAdmin/: false
undefined
error Error rendering /implementation/Theme.TheAdmin/ArticleAdmin/edit.html: false
undefined
error Error rendering /implementation/Theme.TheAdmin/ArticleAdmin/: false
undefined
error Error rendering /implementation/Theme.TheAdmin/ArticleService.html: false
undefined
TypeError: Cannot read properties of undefined (reading 'match')
    at getHash (node_modules/@vuepress/theme-default/util/index.js:13:21)
    at isActive (node_modules/@vuepress/theme-default/util/index.js:47:19)
    at render (node_modules/@vuepress/theme-default/components/SidebarLink.vue:25:0)
    at renderWithStyleInjection (node_modules/vue-loader/lib/runtime/componentNormalizer.js:83:0)
    at createFunctionalComponent (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue\dist\vue.runtime.common.dev.js:3071:30)
    at createComponent (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue\dist\vue.runtime.common.dev.js:3244:12)
    at _createElement (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue\dist\vue.runtime.common.dev.js:3436:15)
    at createElement (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue\dist\vue.runtime.common.dev.js:3368:10)
    at vm._c (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue\dist\vue.runtime.common.dev.js:3505:42)
    at 1.server-bundle.js:1054:492
    at Proxy.renderList (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue\dist\vue.runtime.common.dev.js:2640:16)
    at Proxy.SidebarLinksvue_type_template_id_1da4684a_render (node_modules/@vuepress/theme-default/components/SidebarLinks.vue?5fd7:1:152)
    at VueComponent.Vue._render (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue\dist\vue.runtime.common.dev.js:3559:22)
    at resolve (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue-server-renderer\build.dev.js:8444:27)
    at waitForServerPrefetch (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue-server-renderer\build.dev.js:8316:3)
    at renderComponentInner (C:\Users\i\source\repos\inbornking.net\4.code\2.reading\node_modules\vue-server-renderer\build.dev.js:8455:3)
scil commented 2 years ago

I tried rename index.md to README.md, errors gone.

Why?

Why not I can use index.md?

scil commented 2 years ago

Without this auto sidebar plugin, I still encounter kind of same error.

so it's bond to vuepress itself.

And I think vuepress official doc is not correct. https://github.com/vuejs/vuepress/issues/611

Now I decide to try @nuxt/content


update:

Now I use vuepress v2, yarn and the new version of this plugin, work well.