Build JS instead of html in vite

This commit is contained in:
Daoud Clarke 2023-11-06 20:10:54 +00:00
parent e54f55ad8e
commit d7ad64b4e0

View file

@ -1,12 +1,18 @@
import legacy from '@vitejs/plugin-legacy'
import { resolve } from 'path'
export default {
root: './src',
base: '/static',
publicDir: '../assets',
build: {
outDir: '../dist',
minify: false
outDir: '../dist',
rollupOptions: {
input: {
index: resolve(__dirname, 'src/index.js'),
stats: resolve(__dirname, 'src/stats/index.html'),
},
},
},
plugins: [
legacy({