Questions tagged [ng-build]

223 questions
1
vote
0 answers

Angular 8: ng build production stuck at 11% and system hangs not able to create production build

I am using Angular 8 and trying to create production build. Here is the configuration Angular CLI: 8.1.3 Node: 12.14.1 OS: linux x64 Angular: 8.1.3 ... animations, cli, common, core, forms, language-service ... platform-browser,…
S.H
  • 119
  • 3
  • 13
1
vote
0 answers

ENOENT: dist folder can't be generated by both ng build and ng serve

When I run the angular commands ng build or ng serve, I get the following error and the dist folder is not generated: An unhandled exception occurred: ENOENT: no such file or directory, lstat…
Sandar
  • 11
  • 2
1
vote
1 answer

Angular 12 Differential loading continues generating ES5 bundle when disabled

I have configured my project in order to avoid the ES5 bundle that the build is generating. For that purpose, I have configured the .browserlists and tsconfig.json files as follow: .browserslist file last 1 Chrome version tsconfig.json { …
ÁlvaroSL
  • 71
  • 7
1
vote
0 answers

Can not run ng build

Problem When I run ng build to generate dist folder in project, it show No projects support the 'build' target. Capture error Project Environment angular: 2 angular-cli: 1.0.0-beta.18 node: 6.0.0 Local Environment Angular CLI: 13.0.1 Node:…
Loc Nguyen
  • 19
  • 1
1
vote
2 answers

Angular: serving application on custom context-root with npm start on localhost

I have an Angular application which starts on port 4300 with this configuration: "scripts": { "ng": "ng", "start": "ng serve --port 4300 --host 0.0.0.0 --proxy-config proxy.conf.json", "build": "ng build", "test": "ng test", "lint": "ng…
Alessandro C
  • 3,310
  • 9
  • 46
  • 82
1
vote
0 answers

Angular build failed wtih

When I am trying to ng build the angular project, it failed generating ES5 bundle. But ng serve is working well. Generating ES5 bundles for differential loading... An unhandled exception occurred: Call retries were exceeded See…
Yang
  • 11
  • 2
1
vote
1 answer

Angular 10: ngOnInit not firing in the deployed app version in Firefox when navigating back from the external URL with browser's back button

I see that the life cycle of the deployed Angular application looks different in Firefox. There is a pretty trivial code of the app component: export class AppComponent implements OnInit { public ngOnInit(): void { console.log('OnInit'); …
greatromul
  • 1,069
  • 2
  • 15
  • 42
1
vote
1 answer

Passing parameters to npm ci

Since the introduction of npm ci some time ago, this is the recommended way for building applications - especially for CI environments and so on. I have now the case where I am interested in specifying additional options (e.g. the base href) when…
Anton Sarov
  • 3,712
  • 3
  • 31
  • 48
1
vote
1 answer

How to speed up loading time on initial load in Angular 7?

I have created Angular Application and split the single module into a bunch of smaller feature modules and lazy load them.And removed unnecessary scripts and styles from index.html and load it at component levels. After final deploy files First…
1
vote
0 answers

How to put an entry for angular-redux/store in an angular library's umdModuleIds

I'm trying to create a library that depends on @angular-redux/store but I can't figure out how to put an entry for it at my angular library's umdModuleIds in ng-package.json: "umdModuleIds": { "redux": "Redux", "@angular-redux/store": "???" //…
john.solano
  • 107
  • 6
1
vote
1 answer

Angular : getting two main chunk (duplicate chunks) on build application

Whenever I do build / build --prod I'm getting duplicate chunks with "es5" and "es2015". Can any one help me here to understand this? What is the reason for this? Will this increase the build size?
chethankumar
  • 409
  • 2
  • 5
  • 15
1
vote
3 answers

NullInjectorError: No provider for t! NullInjectorError: StaticInjectorError(ba)[Cw -> t]:

When I run my prod build of my Angular 8 app, I am getting this error in console. The build runs fine and I've included all services in my provider. I've run the following commands but do not get any errors. ng build --prod --optimization=false Is…
roonz11
  • 795
  • 1
  • 13
  • 24
1
vote
1 answer

Font Awesome fonts not loading in Angular afte ng build

I am using Angular 8. I have added the font-awesome path in the angular.json like this. "./node_modules/font-awesome/css/font-awesome.css" However, all the icons were coming as empty boxes (not loading). So, I put all the font-awesome files in the…
joler-botol
  • 442
  • 1
  • 7
  • 22
1
vote
2 answers

Property 'name' does not exist on type 'any[]' during ng build--aot

I have 1 dropdown and 1 input field. Based the selection of dropdown, input field value is set. So i used an array of type any(Array). In my .ts file, i wrote like this Services: Array=[ {name: 'Consultation', price: 100}, {name:…
Sravan Kumar
  • 602
  • 8
  • 22
1
vote
0 answers

Non-ascii characters in "ng build" output

When I run ng build I get some non-ASCII characters in the console output: 15:02:51 info: Microsoft.AspNetCore.SpaServices[0] 15:02:51 i ï½¢wdsï½£: webpack output is served from / I searched for the string i ï½¢wdsï½£ and found it in some…
sashoalm
  • 75,001
  • 122
  • 434
  • 781