1
0
Fork 0

Actually fix Vite

main
dugo3number2 2023-12-15 14:09:31 -06:00
parent 0888637c74
commit aac0722b16
3 changed files with 15 additions and 15 deletions

View File

@ -4,9 +4,9 @@
"version": "0.0.0", "version": "0.0.0",
"type": "module", "type": "module",
"scripts": { "scripts": {
"dev": "vite", "dev": "vite src",
"build": "vite build", "build": "vite build src",
"preview": "vite preview" "preview": "vite preview src"
}, },
"devDependencies": { "devDependencies": {
"glob": "^10.3.10", "glob": "^10.3.10",

12
src/vite.config.js Normal file
View File

@ -0,0 +1,12 @@
import path from "path";
import { glob } from "glob";
import { defineConfig } from 'vite'
export default defineConfig({
build: {
outDir: path.join(__dirname, "dist"),
rollupOptions: {
input: glob.sync(path.resolve(__dirname, "src", "*.html"))
},
},
});

View File

@ -1,12 +0,0 @@
import path from "path";
import glob from "glob";
export default {
root: path.join(__dirname, "src"),
build: {
outDir: path.join(__dirname, "dist"),
rollupOptions: {
input: glob.sync(path.resolve(__dirname, "src", "**/*.html"))
},
},
};