Skip to content

Commit e9f553d

Browse files
committed
Reduce chart bundle size
1 parent cbea407 commit e9f553d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

webpack.config.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,11 @@ module.exports = {
6666
},
6767
symlinks: false,
6868
},
69+
externals: {
70+
// Mark moment as an external to exclude it from the Chart.js build since we don't need to use
71+
// it for anything.
72+
moment: 'moment',
73+
},
6974
plugins: [
7075
new AssetsManifestPlugin({ writeToDisk: true, publicPath: true, integrity: true, integrityHashes: ['sha384'] }),
7176
!isProduction ? new ForkTsCheckerWebpackPlugin({

0 commit comments

Comments
 (0)