Skip to content

Commit 56a59da

Browse files
authored
Vue 3 vite
1 parent fb4f067 commit 56a59da

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

vue/vite.config.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@ import { defineConfig } from 'vite';
22
import laravel from 'laravel-vite-plugin';
33
import vue from '@vitejs/plugin-vue'
44

5-
export default defineConfig({
6-
base: '/', // Default is /build directory
5+
export default defineConfig({
76
plugins: [
87
laravel({
98
input: ['resources/js/app.js'],
@@ -18,4 +17,14 @@ export default defineConfig({
1817
},
1918
}),
2019
],
20+
// Change base url
21+
// base: './', // Default url path is /build directory
22+
// Or change assets dir
23+
build: {
24+
rollupOptions: {
25+
output: {
26+
assetFileNames: 'assets/[ext]/[name][extname]',
27+
},
28+
},
29+
},
2130
});

0 commit comments

Comments
 (0)