This turns the project into a monorepo using pnpm workspaces, dramatically simplifying the build process. It also fixes a lot of bugs and just generally makes the codebase a lot cleaner.
29 lines
728 B
TypeScript
29 lines
728 B
TypeScript
import { resolve } from 'path';
|
|
import { defineConfig } from 'vite';
|
|
import dts from 'vite-plugin-dts';
|
|
|
|
export default defineConfig({
|
|
build: {
|
|
target: 'es2022',
|
|
rollupOptions: {
|
|
input: [
|
|
resolve(__dirname, 'src/index.ts'),
|
|
resolve(__dirname, 'src/solver.ts'),
|
|
resolve(__dirname, 'src/validator.ts'),
|
|
],
|
|
preserveEntrySignatures: "strict",
|
|
output: {
|
|
dir: 'dist',
|
|
entryFileNames: '[name].js',
|
|
preserveModules: false
|
|
}
|
|
},
|
|
minify: true
|
|
},
|
|
resolve: {
|
|
alias: {
|
|
'@': '/src'
|
|
}
|
|
},
|
|
plugins: [dts()]
|
|
}); |