Skip to content

Commit

Permalink
feat: add runtime and react-dom to vite config
Browse files Browse the repository at this point in the history
  • Loading branch information
wonderfulfrog committed Jul 31, 2024
1 parent e3e8c3a commit d24f5e9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,14 @@ export default defineConfig({
rollupOptions: {
// make sure to externalize deps that shouldn't be bundled
// into your library
external: ["react", "react-dom"],
external: ["react", "react-dom", "react/jsx-runtime"],
output: {
// Provide global variables to use in the UMD build
// for externalized deps
globals: {
react: "React",
"react-dom": "ReactDOM",
"react/jsx-runtime": "jsxRuntime",
},
},
},
Expand Down

0 comments on commit d24f5e9

Please sign in to comment.