Making a full bundle #2843
-
Hello, I have created a bundle with the following configuration using ViteJS: // https://vitejs.dev/config/
my question is the following: is there a way to create a single full bundle file? or some way to unify those obtained in the build? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I solved, I use Rollup, here the config file: export default { |
Beta Was this translation helpful? Give feedback.
I solved, I use Rollup, here the config file:
`import {nodeResolve} from '@rollup/plugin-node-resolve';
import replace from '@rollup/plugin-replace';
import terser from '@rollup/plugin-terser';
export default {
input: 'src/spectrum-web-components.js',
output: {
file: 'output/spectrum-web-components-full-bundle.js',
format: 'esm',
inlineDynamicImports: true
},
plugins: [
terser(),
nodeResolve(),
replace({
include: 'node_modules/focus-visible/dist/focus-visible.js',
values: {
'this': 'undefined'
},
preventAssignment: true
})
]
}`