How to configure Bundle Analyzer in Angular?

preview_player
Показать описание
#angular #webpack #performance

This video explains the need to configure a must-have bundle analyzer in Angular and also teaches how to do it step by step.

Related videos and NPM packages

- Video on adding custom webpack configuration in Angular

-Video on tips to reduce the Angular bundle size

npm i -D webpack-bundle-analyzer

- Install moment-locales-webpack-plugin to remove the desired locales from the bundle
npm i -D moment-locales-webpack-plugin

- Install moment-timezone-data-webpack-plugin to remove the desired timezones from the bundle
npm i -D moment-timezone-data-webpack-plugin
Рекомендации по теме
Комментарии
Автор

still working for angular 18? Since i only see the error:

Could't analyze webpack bundle:
TypeError: Cannot read properties of undefined (reading 'filter')

SoulPvPGangstar
Автор

Is there any way to do this without the custom webpack?

Isildur