One of the main differences between dev and build time is how Vite handles dependencies. During build time, [`@rollupjs/plugin-commonjs`](https://github.com/rollup/plugins/tree/master/packages/commonjs) is used to allow importing CJS only dependencies (like React). When using the dev server...
Next generation frontend tooling. It's fast! Contribute to vitejs/vite development by creating an account on GitHub.
rollup在业务中基本很少会有接触到,通常在我们的业务中大部分接触的脚手架,或者自己搭建项目中,我们都...
2 changes: 1 addition & 1 deletion 2 packages/vite/package.json Original file line numberDiff line numberDiff line change @@ -73,7 +73,7 @@ "@babel/types": "^7.20.5", "@jridgewell/trace-mapping": "^0.3.17", "@rollup/plugin-alias": "^4.0.2", "@rollup/plugin-commonjs": "...
vitejs / vite Public Sponsor Notifications Fork 5.8k Star 65.5k Code Issues 441 Pull requests 144 Discussions Actions Projects 1 Security Insights New issue chore(deps): update dependency @rollup/plugin-commonjs to v26 #17431
204: constCJS__export_default= (module.exports == null ? {} : module.exports).default || module.exports; 205: export { 206:CJS__export_defaultas default, ^ 207: } 208: /* [vite-plugin-commonjs] export-statement-E */ Author
2 changes: 1 addition & 1 deletion 2 packages/vite/package.json Original file line numberDiff line numberDiff line change @@ -98,7 +98,7 @@ "@jridgewell/trace-mapping": "^0.3.25", "@polka/compression": "^1.0.0-next.25", "@rollup/plugin-alias": "^5.1.0", "@rollup/plugin-...
vite-plugin-ssr ✅ success vite-plugin-react ✅ success vite-plugin-react-pages ✅ success vite-plugin-react-swc ✅ success vite-plugin-svelte ✅ success vite-plugin-vue ✅ success vite-setup-catalogue ✅ success vitepress ✅ success vitest ✅ success patak-dev merged commit a3ff...
I tried switching a CRA project to Vite and encountered it breaking in the production build because of this bug happening to xmlbuilder. https://github.com/dantman/rollup-commonjs-circular-xmlbuilder-bug I tested it with the beta and it fixed the issue. So I am encouraged there is a ...
Vite will likely never support such dependencies. Contributor Author ashubham commented Jul 30, 2020 @yyx990803 Would you consider having this as optional for anyone getting blocked ? Niputi mentioned this issue Nov 17, 2020 enable transformMixedEsModules option for the @rollup/plugin-commonjs...