Questions tagged [angular2-aot]

Use angular2-aot for questions related to the Angular2 ahead-of-time compiler, which allows developers to deploy pre-compiled JavaScript code and HTML5 markup to the browser rather than TypeScript and Angular templates.

References

431 questions
0
votes
1 answer

Angular Aot : app folder is not generated

I have implemented aot in my Angular 2 project, resolved all errors an finally my "node_modules/.bin/ngc" -p tsconfig-aot.json run successfully but I see only node_modules folder in aot folder and no app folder in it. So where can I get…
sudhir
  • 1,387
  • 3
  • 25
  • 43
0
votes
2 answers

Error 1068: Property does not exist on type angular 2 (AOT)

I am new in angular 2, i am making a "User Register" form but it shows error in "Property does not exist on type" in Phone number Validation. I am compiling in JIT and AOT. In JIT compiler shows error message and run my user register form it is…
Sharma Vikram
  • 2,440
  • 6
  • 23
  • 46
0
votes
2 answers

angular 2 deployment with angular cli - which files do i need to host?

I'm using angular cli v1.0.0-beta.21 and using ng -b -prod -aot I'm getting the expected index.html style.bundle.css main.bundle.js There some files which I don't know what they are for and was hoping you could enlighten…
Han Che
  • 8,239
  • 19
  • 70
  • 116
0
votes
1 answer

Bundling JS with angular2

Can i bundle JS files with angular2 the same way i'm bundling HTML files? I currently declare my JS files and copy them manually with the dist folder to my testing server. is there a way so that i can make angular2 bundle those JS files with it when…
Newbie
  • 386
  • 4
  • 19
0
votes
1 answer

ngc compilation error as typings/index.d.ts' not found

I have downloaded the Tour Of Heroes app from following github. I have been successfully run the app with npm start But when I try to run npm run start-aot Then I am getting the following error. angular2-tour-of-heroes@0.1.0 start-aot…
Partha Sarathi Ghosh
  • 10,936
  • 20
  • 59
  • 84
0
votes
0 answers

Angular2 Web Deployment in VS2015(Framework 4.6)

I am having problem while deploying my Angular2 Vs2015 application. I have created my application and deployed in Server. When i request for LogIn Page for the 1st time. its loading all node_modules and other files and taking nearly 2 mins to load…
0
votes
1 answer

Error running ng serve -aot command in Angular 2 project

I'm having an error when I run my Angular 2 project with the following command: ng serve -aot Stack trace: ERROR in ./src/app/app.module.ngfactory.ts Module build failed: Error:…
GUISSOUMA Issam
  • 2,572
  • 2
  • 16
  • 27
0
votes
1 answer

commonjs in rollup after ngc

I am trying to get my angular 2 project compiled in AoT way. However I am having the following problem. Here is the source code: /// import { Injectable, Inject } from '@angular/core'; import { Http }…
Velissel
  • 77
  • 9
0
votes
1 answer

gettiing OrderModule is not an ngModule error during aot-compilation

I have used angular-cli for scaffolding.I have app module which is bieng loaded by default, while other modules are lazily loaded. while running: ng build -prod --aot 14% building modules 36/37 modules 1 active…
Manish
  • 2,092
  • 16
  • 18
0
votes
1 answer

Angular 2 AoT compile causes application issues and works fine in JiT

I've followed the Angular 2 example from: https://angular.io/docs/ts/latest/cookbook/aot-compiler.html After compiling the application using ngc AoT the routing doesn't work, it just stays on the same page and nothing happens. Since the application…
Loves2Develop
  • 774
  • 1
  • 8
  • 29
0
votes
2 answers

Class has or is using name 'SafeUrl' from external module but cannot be named

I'm using sanitizer.bypassSecurityTrustUrl to put links to blobURL's on the page. This works just fine as long as I don't AoT compile the project. import {DomSanitizer} from '@angular/platform-browser'; export class AppComponent { …
mottosson
  • 3,283
  • 4
  • 35
  • 73
0
votes
1 answer

Angular2 SystemJs, Ahead of Time Compilation with Gulp

Can anyone please guide how to use Gulp for Ahead of Time compilation of a Angular2 project that uses SystemJs. I mean to automate all steps mentioned in https://angular.io/docs/ts/latest/cookbook/aot-compiler.html i.e. generate NgFactories,…
Naveed Ahmed
  • 10,048
  • 12
  • 46
  • 85
0
votes
2 answers

Angular AOT compilation failed

I need to put a website in production soon and am looking into the AOT to improve performance (my app needs about 3-4 secs to load on Chrome, 8-10 secs on Firefox, which is just not possible for production). I followed the guide on…
kinkaz
  • 53
  • 8
0
votes
1 answer

Making AoT compatible DI

I had a working project with angular rc4 which is breaking down after updating it to angular 2.0.0 I'm having the following error: Error encountered resolving symbol values statically. Calling function 'createStore', function calls are not…
Dee
  • 909
  • 3
  • 10
  • 18
0
votes
1 answer

Angular2: this.http.get(...).map is not a function but only when AoT compilation

I'm using a service to make http get requests: import { Headers, Http } from '@angular/http'; import { Observable } from 'rxjs'; import 'rxjs/add/operator/map'; .... classcode..... getOffices(): Observable { const url =…
1 2 3
28
29