Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Serve Angular14 without minification/uglification

Is there a way to disable all sorts of minification/uglification in the SERVE process, so it doesn't rename class names that are part of the error message?

It's the last Angular14 version.

Error message I'm receiving:

NullInjectorError: R3InjectorError(i)[e -> InjectionToken Application Initializer -> [object Object] -> j -> b -> Tt -> J -> Tt -> Tt -> Tt]: NullInjectorError: No provider for Tt!

like image 359
Václav Mikeska Avatar asked Aug 02 '26 04:08

Václav Mikeska


1 Answers

The serve process should NOT minify and uglify your code.

If it does, check your angular.json file and in the serve part, set this

"buildOptimizer": false,
"optimization": false,
"vendorChunk": true,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
like image 55
MGX Avatar answered Aug 04 '26 19:08

MGX



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!