You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
✖ building client + server bundles...
build error:
[vite:load-fallback] Could not load vue/dist/vue.esm-bundler.js/server-renderer (imported by node_modules/.pnpm/vitepress@1.6.3_@algolia+client-search@5.21.0_@types+node@22.13.10_async-validator@4.2.5_axio_dswlsf7js4zfbtehsxenr54umq/node_modules/vitepress/dist/client/app/ssr.js): ENOENT: no such file or directory, open 'E:\learn-collect\vite\potato-vite-plugins\pt-docs\vue\dist\vue.esm-bundler.js\server-renderer'
[vite:load-fallback] Could not load vue/dist/vue.esm-bundler.js/server-renderer (imported by node_modules/.pnpm/vitepress@1.6.3_@algolia+client-search@5.21.0_@types+node@22.13.10_async-validator@4.2.5_axio_dswlsf7js4zfbtehsxenr54umq/node_modules/vitepress/dist/client/app/ssr.js): ENOENT: no such file or directory, open 'E:\learn-collect\vite\potato-vite-plugins\pt-docs\vue\dist\vue.esm-bundler.js\server-renderer'
at async open (node:internal/fs/promises:639:25)
at async Object.readFile (node:internal/fs/promises:1242:14)
at async Object.load (file:///E:/learn-collect/vite/potato-vite-plugins/pt-docs/node_modules/.pnpm/vite@5.4.14_@types+node@22.13.10_less@4.2.2/node_modules/vite/dist/node/chunks/dep-CHZK6zbr.js:65249:25)
at async PluginDriver.hookFirstAndGetPlugin (file:///E:/learn-collect/vite/potato-vite-plugins/pt-docs/node_modules/.pnpm/rollup@4.36.0/node_modules/rollup/dist/es/shared/node-entry.js:21867:28)
at async file:///E:/learn-collect/vite/potato-vite-plugins/pt-docs/node_modules/.pnpm/rollup@4.36.0/node_modules/rollup/dist/es/shared/node-entry.js:20990:33
at async Queue.work (file:///E:/learn-collect/vite/potato-vite-plugins/pt-docs/node_modules/.pnpm/rollup@4.36.0/node_modules/rollup/dist/es/shared/node-entry.js:22077:32)
ELIFECYCLE Command failed with exit code 1.
Reproduction
Add the following configuration to the config.mjs file.
When I don't add the vue: "vue/dist/vue.esm-bundler.js" configuration, the build can succeed.
I found that 'E: \ pt docs \ ode_modules . pnpm'\ vitepress@1.6.3_ @algolia+ client-search@5.21.0_ @types+ node@22.13.10_async-validator@the code in the file "4.2.5a_xi_odswsf7js4zfbtehsxenr54umq \ ode_modules \ vitepress \ dist \ client \ app \ ssr. js" refers to "vue/server renderer". The code is as follows:
// entry for SSRimport{renderToString}from'vue/server-renderer';import{createApp}from'./index';exportasyncfunctionrender(path){const{
app,
router
}=awaitcreateApp();awaitrouter.go(path);constctx={content: '',vpSocialIcons: newSet()};ctx.content=awaitrenderToString(app,ctx);returnctx;}
When I changed the configuration to the following alternative solution, I still couldn't solve it
Option 1:
Indeed, you are right. Previously, when I configured the following settings, I did not carefully check the new error logs. After investigation, I found the problem. Since the vue version in my document is the latest, it may not match the vue@3.4.38 required by the @vitepress-demo-preview/component plugin. After switching to 3.4.38, the packaging was successful.
Describe the bug
When I try to run vitepress build I get:
Reproduction
config.mjs
file.Additional context
When I don't add the vue: "vue/dist/vue.esm-bundler.js" configuration, the build can succeed.
I found that 'E: \ pt docs \ ode_modules . pnpm'\ vitepress@1.6.3_ @algolia+ client-search@5.21.0_ @types+ node@22.13.10_async-validator @the code in the file "4.2.5a_xi_odswsf7js4zfbtehsxenr54umq \ ode_modules \ vitepress \ dist \ client \ app \ ssr. js" refers to "vue/server renderer". The code is as follows:
When I changed the configuration to the following alternative solution, I still couldn't solve it
Option 1:
Option 2:
The text was updated successfully, but these errors were encountered: