-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathvite.sentry.config.mjs
42 lines (41 loc) · 1.05 KB
/
vite.sentry.config.mjs
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
36
37
38
39
40
41
42
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
import viteTsconfigPaths from 'vite-tsconfig-paths';
import svgrPlugin from 'vite-plugin-svgr';
import { sentryVitePlugin } from '@sentry/vite-plugin';
import { version } from './package';
export default defineConfig({
server: {
port: 3001,
host: 'localhost',
},
build: {
sourcemap: process.env.NODE_ENV === 'production',
sourcemapFile: '/static',
emptyOutDir: true,
outDir: 'build',
rollupOptions: {
output: {
entryFileNames: 'assets/[name][hash].js',
chunkFileNames: 'assets/[name][hash].js',
assetFileNames: 'assets/[name][hash].[ext]',
},
},
},
plugins: [
react(),
viteTsconfigPaths(),
svgrPlugin(),
sentryVitePlugin({
org: 'alkemio',
project: 'alkemio',
debug: true,
release: {
name: `client-web@v${version}`,
version,
create: process.env.NODE_ENV === 'production',
},
authToken: process.env.VITE_APP_SENTRY_AUTH_TOKEN,
}),
],
});