feat: add sentry sourcemap upload

This commit is contained in:
2024-03-25 13:18:34 +08:00
parent a81bb5ed53
commit fac90c4a9c
5 changed files with 205 additions and 109 deletions

View File

@@ -1,13 +1,23 @@
import { sentryVitePlugin } from "@sentry/vite-plugin";
import { resolve } from "path";
import react from "@vitejs/plugin-react";
import { defineConfig } from "vite";
export default defineConfig({
plugins: [react()],
plugins: [react(), sentryVitePlugin({
org: "sentry",
project: "ds-viewer",
url: "https://sentry.yoshino-s.xyz/"
})],
resolve: {
alias: {
"@/": `${resolve(__dirname, "src")}/`,
},
},
});
build: {
sourcemap: true
}
});