fix: Configure Vite to externalize Node.js modules for client build
This commit is contained in:
@@ -18,14 +18,12 @@ export default defineNuxtConfig({
|
||||
nitro: {
|
||||
experimental: {
|
||||
wasm: true
|
||||
}
|
||||
},
|
||||
externals: {
|
||||
inline: ['better-sqlite3'],
|
||||
external: ['path', 'fs', 'crypto', 'bcryptjs']
|
||||
},
|
||||
rollupConfig: {
|
||||
output: {
|
||||
sourcemap: false
|
||||
vite: {
|
||||
build: {
|
||||
rollupOptions: {
|
||||
external: ['better-sqlite3', 'path', 'fs', 'crypto', 'bcryptjs']
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user