Skip to content

Commit

Permalink
adjusted vite config
Browse files Browse the repository at this point in the history
  • Loading branch information
Tinoooo committed Sep 10, 2024
1 parent af81538 commit 2f27668
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
7 changes: 6 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@
"effects",
"fx"
],
"maintainers": [
"Alvaro Saburido (https://github.com/alvarosabu/)",
"Tino Koch (https://github.com/Tinoooo)"
],
"exports": {
"./three": {
"types": "./dist/three.d.ts",
Expand All @@ -27,7 +31,8 @@
"./pmndrs": {
"types": "./dist/pmndrs.d.ts",
"import": "./dist/pmndrs.js"
}
},
"./*": "./*"
},
"files": [
"*.d.ts",
Expand Down
11 changes: 7 additions & 4 deletions vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@ export default defineConfig({
watch: {
include: [resolve(__dirname, 'src')],
},
lib: {
entry: {
three: resolve(__dirname, 'src/core/three/index.ts'),
pmndrs: resolve(__dirname, 'src/core/pmndrs/index.ts'),
},
formats: ['es'],
},
rollupOptions: {
plugins: [
analyze(),
Expand All @@ -46,10 +53,6 @@ export default defineConfig({
}),
],
external: ['three', 'vue', '@tresjs/core', 'postprocessing', '@vueuse/core'],
input: {
three: resolve(__dirname, 'src/core/three/index.ts'),
pmndrs: resolve(__dirname, 'src/core/pmndrs/index.ts'),
},
output: {
entryFileNames: '[name].js',
exports: 'named',
Expand Down

0 comments on commit 2f27668

Please sign in to comment.