Skip to content

Commit

Permalink
build: rollup manual chunks
Browse files Browse the repository at this point in the history
  • Loading branch information
jlsuh committed Feb 3, 2024
1 parent 3fe8e5f commit 3780b15
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,19 @@ import { defineConfig } from "vite";

export default defineConfig({
plugins: [react()],
build: {
rollupOptions: {
output: {
manualChunks(id) {
if (id.indexOf("node_modules") !== -1) {
return id
.toString()
.split("node_modules/")[1]
.split("/")[0]
.toString();
}
},
},
},
},
});

0 comments on commit 3780b15

Please sign in to comment.