-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvite.config.ts
More file actions
35 lines (34 loc) · 991 Bytes
/
Copy pathvite.config.ts
File metadata and controls
35 lines (34 loc) · 991 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import pluginTypescript from "@rollup/plugin-typescript";
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
// https://vite.dev/config/
export default defineConfig({
plugins: [react(),
pluginTypescript({
tsconfig: "tsconfig.json",
sourceMap: true,
inlineSources: true
})
],
base: "./",
build: {
target: "es2023",
sourcemap: true,
assetsInlineLimit: 0,
rollupOptions: {
output: {
// Prevent hashes from turning up in the output files.
// We don't need to cache anything at the moment, since we run inside SP.
// This prevents multiple hashed versions of the same file ending up in parts of the AppDev repo.
entryFileNames: `assets/[name].js`,
chunkFileNames: `assets/[name].js`,
assetFileNames: `assets/[name].[ext]`
}
}
},
test: {
globals: true,
environment: 'jsdom',
setupFiles: "setup.ts",
}
})