samuelventura / athasha

Automation Now
MIT License
0 stars 0 forks source link

Reduce size of monaco editor #80

Open samuelventura opened 2 years ago

samuelventura commented 2 years ago

Vite build warns about the large size:

dist/assets/editor.f7c6b28d.js                         2501.30 KiB / gzip: 634.07 KiB

(!) Some chunks are larger than 500 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 25.71s.
samuelventura commented 2 years ago

These workers are built by default in production:

monacoeditorwork/
monacoeditorwork/css.worker.bundle.js
monacoeditorwork/editor.worker.bundle.js
monacoeditorwork/html.worker.bundle.js
monacoeditorwork/json.worker.bundle.js
monacoeditorwork/ts.worker.bundle.js