Initial TrueGrowth source import
This commit is contained in:
35
packages/utils/vite.config.ts
Normal file
35
packages/utils/vite.config.ts
Normal file
@@ -0,0 +1,35 @@
|
||||
/// <reference types="vitest" />
|
||||
import { defineConfig } from 'vite';
|
||||
import { resolve } from 'path';
|
||||
import dts from 'vite-plugin-dts';
|
||||
|
||||
export default defineConfig({
|
||||
build: {
|
||||
lib: {
|
||||
entry: resolve(__dirname, 'src/index.ts'),
|
||||
name: 'AituUtils',
|
||||
formats: ['es', 'cjs'],
|
||||
fileName: (format) => `index.${format === 'es' ? 'mjs' : 'js'}`,
|
||||
},
|
||||
rollupOptions: {
|
||||
external: [],
|
||||
},
|
||||
sourcemap: true,
|
||||
outDir: '../../dist/utils',
|
||||
},
|
||||
plugins: [
|
||||
dts({
|
||||
entryRoot: 'src',
|
||||
outDir: '../../dist/utils',
|
||||
}),
|
||||
],
|
||||
test: {
|
||||
globals: true,
|
||||
environment: 'node',
|
||||
include: ['src/**/*.test.ts'],
|
||||
coverage: {
|
||||
provider: 'v8',
|
||||
reporter: ['text', 'json', 'html'],
|
||||
},
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user