How to simplify debugging of production code in #angular 👀

preview_player
Показать описание
Level up your Angular skills with my Advanced Courses 🚀

Learn a simple trick that will simplify the debugging of the production code of the angular applications, making it much more readable.
Рекомендации по теме
Комментарии
Автор

For other people that might have the same problem: `.angular` folder caches the last build, and if you don't change your code between builds it will reuse the last build and won't notice the change in flag `NG_BUILD_MANGLE`. So the solution is to either make change in code or delete `.angular` folder in between builds without changes.

Thanks @Dimitri for help in solving this!

asgarov
Автор

Does this bring any advantage over using source maps?

kaischonberger
Автор

Is there a way we can automatically remove console.logs upon build?

CodingAbroad
Автор

that was crazy, making debug in min file in production, someone has made it sometime! i had never heard something like that before, this is like make debug in compile version of the program

haroldpepete
Автор

Cool, but how much bigger will be the bundle?

JuliaSleeps
Автор

is it okay if I go as far as setting "sourceMap": true when I want to debug?

wawawawa