setup proxy for dev
This commit is contained in:
@@ -10,6 +10,16 @@ export default defineNuxtConfig({
|
||||
preset: "static"
|
||||
},
|
||||
vite: {
|
||||
server: {
|
||||
proxy: {
|
||||
"^/node_modules/.*": {
|
||||
target: "http://localhost:3000",
|
||||
changeOrigin: true,
|
||||
rewrite: (path) =>
|
||||
path.replace(/^\/node_modules\//, "/_nuxt/node_modules/")
|
||||
}
|
||||
}
|
||||
},
|
||||
$client: {
|
||||
plugins: [
|
||||
topLevelAwait({
|
||||
|
||||
Reference in New Issue
Block a user