-
Notifications
You must be signed in to change notification settings - Fork 2
/
vite.config.js
42 lines (38 loc) · 1.08 KB
/
vite.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import WindiCSS from 'vite-plugin-windicss'
import {resolve} from 'path'
export default ({command}) => ({
// please update the path name [chkilel-vitewind] to your theme folder name
base: command === 'serve' ? '' : '/themes/chkilel-vitewind/public/build/',
publicDir: 'fake_dir_so_nothing_gets_copied',
processCssUrls: true,
build: {
manifest: true,
outDir: 'public/build',
rollupOptions: {
input: [
'resources/js/app.js',
'resources/js/home.js'
],
},
},
plugins: [
WindiCSS(),
{
name: 'reload-template',
handleHotUpdate({file, server}) {
if (file.endsWith('.htm')) {
server.ws.send({
type: 'full-reload',
path: '*',
});
}
},
},
],
// See https://dev.to/jarraga/comment/1c7ok
// resolve: {
// alias: {
// '@': resolve(__dirname, './resources/js')
// }
// }
});