-
Notifications
You must be signed in to change notification settings - Fork 3
/
vite.config.mjs
38 lines (37 loc) · 1.79 KB
/
vite.config.mjs
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
import { resolve } from 'path'
import { defineConfig } from 'vite'
import { nodeResolve } from '@rollup/plugin-node-resolve'
export default defineConfig({
base: '/demo/',
// nodeResolve is needed to import melange runtime libraries in output
// directory's `node_modules` directory. See
// https://github.com/melange-re/melange-for-react-devs/pull/16#discussion_r1455989106
plugins: [nodeResolve()],
server: {
watch: {
ignored: ['**/_opam']
}
},
build: {
rollupOptions: {
input: {
'main': resolve(__dirname, 'index.html'),
'counter': resolve(__dirname, 'src/counter/index.html'),
'numeric-types': resolve(__dirname, 'src/numeric-types/index.html'),
'celsius-converter-exception': resolve(__dirname, 'src/celsius-converter-exception/index.html'),
'celsius-converter-option': resolve(__dirname, 'src/celsius-converter-option/index.html'),
'order-confirmation': resolve(__dirname, 'src/order-confirmation/index.html'),
'styling-with-css': resolve(__dirname, 'src/styling-with-css/index.html'),
'better-sandwiches': resolve(__dirname, 'src/better-sandwiches/index.html'),
'better-burgers': resolve(__dirname, 'src/better-burgers/index.html'),
'sandwich-tests': resolve(__dirname, 'src/sandwich-tests/index.html'),
'cram-tests': resolve(__dirname, 'src/cram-tests/index.html'),
'burger-discounts': resolve(__dirname, 'src/burger-discounts/index.html'),
'discounts-lists': resolve(__dirname, 'src/discounts-lists/index.html'),
'promo-codes': resolve(__dirname, 'src/promo-codes/index.html'),
'promo-component': resolve(__dirname, 'src/promo-component/index.html'),
'order-with-promo': resolve(__dirname, 'src/order-with-promo/index.html'),
},
},
},
});