Closed N0W0RK closed 1 month ago
Add this to .vitepress/config:
import { defineConfig } from 'vitepress'
import { createRequire } from 'node:module'
const require = createRequire(import.meta.url)
export default defineConfig({
// ...
vite: {
resolve: {
alias: {
'vue/server-renderer': require.resolve('vue/server-renderer'),
'vue': require.resolve('vue')
}
}
}
})
Will be fixed in next version.
Describe the bug
When using vitepress in a yarn workspace, the build script erorrs. Depending on the setup, there are issues importing vue or even vitepress itself.
Reproduction
Expected behavior
Clean build of the static website.
System Info
Additional context
No response
Validations