fix: add vite alias to deduplicate react versions
Some checks failed
armco-org/icon-spot/pipeline/head There was a failure building this commit
Some checks failed
armco-org/icon-spot/pipeline/head There was a failure building this commit
This commit is contained in:
@@ -1,11 +1,18 @@
|
||||
import { defineConfig } from "vitest/config"
|
||||
import react from "@vitejs/plugin-react"
|
||||
import { config } from "dotenv"
|
||||
import path from "path"
|
||||
|
||||
config()
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
export default defineConfig({
|
||||
resolve: {
|
||||
alias: {
|
||||
react: path.resolve(__dirname, "./node_modules/react"),
|
||||
"react-dom": path.resolve(__dirname, "./node_modules/react-dom"),
|
||||
},
|
||||
},
|
||||
define: {
|
||||
"process.env.NODE_ENV": JSON.stringify(process.env.NODE_ENV),
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user