Skip to content

Commit

Permalink
Add sourcemaps for React 18.2
Browse files Browse the repository at this point in the history
  • Loading branch information
markerikson committed Jun 25, 2024
1 parent 5746436 commit fafecb3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { defineConfig, loadEnv } from "vite";
import react from "@vitejs/plugin-react";
import eslint from "vite-plugin-eslint";
import istanbul from "vite-plugin-istanbul";
import { ViteReactSourcemapsPlugin } from "@acemarke/react-prod-sourcemaps";

export default defineConfig(({ command, mode }) => {
const env = loadEnv(mode, process.cwd(), "VITE");
Expand All @@ -26,6 +27,7 @@ export default defineConfig(({ command, mode }) => {
exclude: ["node_modules", "cypress", "dist"],
forceBuildInstrument: true,
}),
ViteReactSourcemapsPlugin({ debug: false, preserve: false }),
],
// to get aws amplify to work with vite
resolve: {
Expand Down

0 comments on commit fafecb3

Please sign in to comment.