work on serialport and events
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
import { defineConfig } from 'vite'
|
||||
import eslint from 'vite-plugin-eslint'
|
||||
import { builtinModules } from "module";
|
||||
|
||||
// https://vitejs.dev/config
|
||||
export default defineConfig({
|
||||
mode: 'development',
|
||||
resolve: {
|
||||
// Some libs that can run in both Web and Node.js, such as `axios`, we need to tell Vite to build them in Node.js.
|
||||
browserField: false,
|
||||
@@ -15,4 +17,10 @@ export default defineConfig({
|
||||
failOnError: false,
|
||||
}),
|
||||
],
|
||||
build: {
|
||||
minify: false, //process.env.MODE !== "development",
|
||||
rollupOptions: {
|
||||
external: ["electron", "serialport", ...builtinModules]
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user