Open bmthd opened 3 months ago
build: {
lib: {
entry: {
index: resolve(__dirname, "src/index.ts"),
},
formats: ["es", "cjs"],
},
rollupOptions: {
output: {
preserveModules: true,
preserveModulesRoot: "src",
},
external: [
...Object.keys(dependencies),
...Object.keys(peerDependencies),
],
},
},
plugins: [react()],
});
https://zenn.dev/toaru_fe/articles/5128fb6a6c21d2