kalisio / kano

Map and weather forecast data explorer in 2D/3D
https://kalisio.github.io/kano/
MIT License
24 stars 7 forks source link

Optimize bundle size #15

Open claustres opened 5 years ago

claustres commented 5 years ago

Using Cesium generates different chunks of 15MB, we need to optimize as much as possible by at least sharing a single Cesium chunk and ensure it is only loaded when 3D view is active.

Related to https://github.com/kalisio/kMap/issues/1.

claustres commented 5 years ago

Creating chunks with shared dependencies between dynamic chunks does not seem to be really possible with webpack 3, wepback 4 seems to make this easier:

However Webpack 4 migration is not yet planned, probably better to include Cesium in shared vendor chunk.

claustres commented 3 years ago

Another solution is also to allow to build a version of the app without 3D activity.