Questions tagged [ng-build]
223 questions
1
vote
1 answer
Angular 9 production build doesn't create named chunk file
I tried to build the angular application in production with the chunk name as the module name.
In angular 7 i have set namedChunks: true which build the projects with named chunks like below image
I tried the same in angular 9 but instead of the…

Nidhin Kumar
- 3,278
- 9
- 40
- 72
1
vote
0 answers
How do I select between appsettings.json and appsettings.Development.json when pushing to dev server and prod server?
How do I make my application use appsettings.json on a production server, and appsettings.Development.json on a development server?

chuckd
- 13,460
- 29
- 152
- 331
1
vote
0 answers
After building and publishing to IIS I always see production build when debug is used in publish commands
I'm having a problem installing a dev version of my Angular/Dotnet app to IIS.
It seems like even when building the project as a dev/debug version and running it in IIS, the app informs me via a startup email I've created that it's always in…

chuckd
- 13,460
- 29
- 152
- 331
1
vote
1 answer
Can't resolve all parameters (AOT, buildOptimizer) on Staging & Prod (ng serve works)
I just upgraded from 5 to 8.
It works (and really fast) when ng-serve. It also works when I do ng-build.
But when I tell it to build on
ng build --configuration=staging
I get
ERROR in Can't resolve all parameters for CandidateViewComponent…

dash
- 387
- 1
- 11
1
vote
0 answers
Customize the distribution of the built files, in angular 8
what I want to do is separate the modules that I have created in my Angular project from the 'dist' folder when I build. I have tried to use WebPack but the truth could not be achieved, or I have not implemented it well. I've been stuck in this…

Fernando
- 115
- 1
- 3
- 10
1
vote
1 answer
Error building with ng build --prod. Fine without --prod flag and ng serve
I have a project that built fine with ng build --prod until I upgraded the version of TypeScript from 2.72 to 2.92 in my package.json.
After upgrading, I now get the following error:
ERROR in Cannot read property 'Symbol(Symbol.iterator)' of…

NiallMitch14
- 1,198
- 1
- 12
- 28
1
vote
1 answer
cat command equivalent in windows for angular build process
So I am trying to create my first web component implementation using this article.
However, I am finding it hard to execute one particular command(I am using windows) which is meant for linux:
"package": "cat…

Shail_bee
- 499
- 4
- 24
1
vote
1 answer
Angular 8 - ng build prod shows errors while ng serve works - Unexpected value 'undefined' imported by the module
My application builds and runs fine when using ng serve but shows errors when using ng build --prod. The error is in a dependency under /node_modules/ so not sure how to fix this?
Error message:
ERROR in Unexpected value 'undefined' imported by the…

Suren Konathala
- 3,497
- 5
- 43
- 73
1
vote
1 answer
ng build throws Cannot read property 'startTag' of null exception
I want to publish my Angular 8 app to IIS. Then I've started to follow the deployment instructions.
When I build my project on prod mode with base-href, operation throws an error. If I build in development mode(just ng build), there is no error but…

Mumin Ka
- 725
- 9
- 19
1
vote
1 answer
Error building .js files with ng build on lib
I have an app that I am trying to convert to use angular cli (v7). The app is in working order.
The app consists of 2 sites and a common lib:
- ui-site-1
- ui-site-2
- ui-lib
I am using ng build to build and package UI-lib but there are errors on…

Oam Psy
- 8,555
- 32
- 93
- 157
1
vote
0 answers
angular-alert-module build is not working
"angular-alert-module": "^2.0.3"
build is not working with this module in angular 7 version
getting following error
ERROR in ./node_modules/angular-alert-module/alerts.ngfactory.js
Module not found: Error: Can't resolve 'alerts' in
…

Manikanta Reddy
- 849
- 9
- 23
1
vote
2 answers
Can't run Angular site because my angular.json file paths mismatch with what ng build creates
New to Angular and after running ng build I see all the files it created in the folder I defined.
In my Angular.json file I'm building to
"outputPath": "../DatingApp.API/wwwroot"
but the rest of the Angular.json file doesn't seem to match with the…

chuckd
- 13,460
- 29
- 152
- 331
1
vote
1 answer
Ng build The ..\src\environments\environment.dev.ts path in file replacements does not exist
I'm trying to do ng build --configuration=development but it gives the following error:
The
C:\Users\Marina\Desktop\heliosFrontEnd_admin\src\environments\environment.dev.ts
path in file replacements does not exist. Error: The
…

Usr
- 2,628
- 10
- 51
- 91
1
vote
1 answer
Export different objects from the same file to different NgModules
Background:
I am developing an application that will utilize angular's lazy loading mechanism (I'm using 7.2.0). I have several feature-routing.module.ts that handle the routing of said lazily loaded modules.
On the AppModule side I would like to…

foxSays
- 88
- 6
1
vote
1 answer
Angular CLI not copying assets folder to dist
I have an app that was in Angular 4 with a custom build system. I am trying to convert it to Angular 6 using ng-cli. However, I am having trouble getting the ng build command to copy the src/assets folder to dist.
This is the relevant part of my…

naman1901
- 305
- 4
- 16