Comments (6)
Can you provide a example project to reproduce the problem? I found it works in the project initialized by vite-cli.
from vite-plugin-chunk-split.
Sorry, not at the time, but it is reproducible when you use @ionic/react package
from vite-plugin-chunk-split.
Finding similar, React 18, Ionic, Vite 3.0.8. Tried just the example with the react-vendor.
Before:
➜ rm -rf build && yarn build
yarn run v1.22.18
$ tsc --noEmit && vite build
vite v3.0.8 building for production...
✓ 590 modules transformed.
build/index.html 1.05 KiB
build/assets/swipe-back.b38f4a88.js 0.65 KiB / gzip: 0.45 KiB
build/assets/status-tap.696bf4f4.js 0.47 KiB / gzip: 0.33 KiB
build/assets/index10.86b21fec.js 1.79 KiB / gzip: 0.88 KiB
build/assets/input-shims.9072cc79.js 4.44 KiB / gzip: 1.93 KiB
build/assets/md.transition.e8122942.js 0.92 KiB / gzip: 0.50 KiB
build/assets/web.b7cabcff.js 0.35 KiB / gzip: 0.24 KiB
build/assets/ios.transition.4ba8ffef.js 9.19 KiB / gzip: 2.60 KiB
build/assets/index.d015e152.css 31.42 KiB / gzip: 6.06 KiB
build/assets/swiper.bundle.a76d5250.js 93.45 KiB / gzip: 25.24 KiB
build/assets/index.6edf5f23.js 1972.70 KiB / gzip: 519.72 KiB
(!) Some chunks are larger than 600 KiB after minification. Consider:
- Using dynamic import() to code-split the application
- Use build.rollupOptions.output.manualChunks to improve chunking: https://rollupjs.org/guide/en/#outputmanualchunks
- Adjust chunk size limit for this warning via build.chunkSizeWarningLimit.
✨ Done in 16.65s.
After:
➜ rm -rf build && yarn build
yarn run v1.22.18
$ tsc --noEmit && vite build
vite v3.0.8 building for production...
✓ 590 modules transformed.
build/index.html 1.13 KiB
build/assets/swipe-back.0ca92795.js 0.65 KiB / gzip: 0.46 KiB
build/assets/index10.8e1fac96.js 1.79 KiB / gzip: 0.88 KiB
build/assets/status-tap.0fb7f632.js 0.47 KiB / gzip: 0.34 KiB
build/assets/web.6f60cc13.js 0.35 KiB / gzip: 0.24 KiB
build/assets/input-shims.9ecdd870.js 4.45 KiB / gzip: 1.94 KiB
build/assets/index.d015e152.css 31.42 KiB / gzip: 6.06 KiB
build/assets/index.f703b555.js 67.40 KiB / gzip: 18.66 KiB
build/assets/swiper.bundle.a76d5250.js 93.45 KiB / gzip: 25.24 KiB
build/assets/vendor.c6e65f37.js 1916.38 KiB / gzip: 503.39 KiB
(!) Some chunks are larger than 600 KiB after minification. Consider:
- Using dynamic import() to code-split the application
- Use build.rollupOptions.output.manualChunks to improve chunking: https://rollupjs.org/guide/en/#outputmanualchunks
- Adjust chunk size limit for this warning via build.chunkSizeWarningLimit.
✨ Done in 16.26s.
from vite-plugin-chunk-split.
same. It does not work on vite 3.
Are you going to fix it @sanyuan0704 ?
from vite-plugin-chunk-split.
I need to find the reproduction way.
from vite-plugin-chunk-split.
I need to find the reproduction way.
OK,i have resolved the problem now.The reason is that vite 3.0 exposes pure esm format only.I have adopt it in latest plugin version.
from vite-plugin-chunk-split.
Related Issues (20)
- explain difference to rollupOptions.output.manualChunks HOT 2
- dependencies are not bundled
- unbundle: more control over vendor / async-vendor HOT 2
- Vite 4 Support HOT 9
- 使用了vite-plugin-chunk-split无法生成正确的sourcemap 这要怎么解决呢? HOT 2
- build error
- What is the purpose of `__commonjsHelpers__.js`? HOT 1
- Chunks from `customSplitting` get imported in every entry HOT 1
- 按目录结构编译一个App项目
- update outdated peer dependency (getting warnings on installation) HOT 1
- 在 vitepress 中报错。
- 在[email protected]上报错 HOT 5
- monorepo: Cannot find package HOT 5
- 引入包报错 HOT 3
- Invalid substitution in "output.chunkFileNames" pattern, can be neither absolute nor relative path. HOT 4
- At the beginning of compilation, the introduction method of request() is not supported HOT 2
- Use import instead of require HOT 1
- 在uniapp中拆包策略不生效
- this plugin uses too much memory HOT 2
- Node 20, Vite 5, pnpm 9 报错 `Error: Cannot find package ...` HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vite-plugin-chunk-split.