Questions tagged [angular-ivy]

Ivy is the code name for Angular's next-generation compilation and rendering pipeline. Use this tag for Angular questions which are specific to only the rendering engine.

Ivy is the code name for Angular's next-generation compilation and rendering pipeline. With the version 9 release of Angular, the new compiler and runtime instructions are used by default instead of the older compiler and runtime, known as View Engine.

194 questions
116
votes
12 answers

Want to upgrade project from Angular v5 to Angular v6

As Angular 6 is here, I want to upgrade or move my angular 5 client application to angular 6, but I'm not getting any tutorial or anything which can guide me through. According to me I just need to run a new Angular CLI and then have to move my…
Abhishek Chokra
  • 1,247
  • 2
  • 6
  • 14
35
votes
2 answers

What do I need to cache in my CI job to avoid ngcc recompiling each time?

With angular 9 and it's new compilation engine IVY, my CI build times have increased substantially. This is of course is because ngcc is ran on many modules. e.g. Compiling @angular/core : es2015 as esm2015 Compiling @angular/common : es2015 as…
maximedupre
  • 3,597
  • 4
  • 24
  • 56
32
votes
1 answer

Why entryComponents is not necessary anymore in Angular 9/ivy compiler?

Can anyone give a clear explanation of why in the IVY compiler, entry components API Is not necessary anymore?. In other words what was change internally so that Angular suddenly doesn't need a heads up that you are going to create component…
Ariel Henryson
  • 1,150
  • 9
  • 13
17
votes
2 answers

Jasmine Angular 9 test failing because 'unreachable' stack trace at injectableDefOrInjectorDefFactory

I created an Angular application under 4. I have migrated from version to version and am currently latest version 9. I was reviewing my tests. I have a Login component that I had 3 working tests and now all are failing. It is now returning the…
Phil Huhn
  • 1,487
  • 1
  • 10
  • 23
17
votes
2 answers

Value at position 0 while updating from Angular 8 to 9

I was updating my project from Angular 8 to 9 when after following the update guide (+ running npm update) on update.angular.io and trying to compile the website using ng serve I get the following error: ERROR in Failed to compile entry-point…
Munchkin
  • 503
  • 1
  • 7
  • 25
13
votes
9 answers

This constructor is not compatible with Angular Dependency Injection because its dependency at index 0 of the parameter list is invalid

In my Angular 9 app, I have an abstract class: export abstract class MyAbstractComponent { constructor( protected readonly cd: ChangeDetectorRef, ) { super(); } // ... } and a Component extending it: @Component({ // ... }) export…
12
votes
2 answers

Should __ngcc_entry_points__.json be added to source control

During the update to Angular 9.1, a file called __ngcc_entry_points__.json appeared in all my root folders in the project. Should this file be added to source control, or ignored? It seems to just contain some hash information, so I assume it can be…
Rasmus Hansen
  • 1,290
  • 1
  • 14
  • 26
11
votes
4 answers

Angular 9 "Error: This constructor was not compatible with Dependency Injection."

This weird error, that I don't remember seeing pre-Ivy, has popped up in the setup of a new app created with the latest Angular 9 CLI. Looks like it could be a bug with Ivy? Any ideas on how to fix would be greatly appreciated. Error result from ng…
Andrew
  • 920
  • 1
  • 9
  • 17
11
votes
1 answer

What does Angular Ivy specifically allow us to do in regards to manual change detection?

This article mentions that Ivy opens a few possibilities for the future though. It should now be possible to run an application without zone.js, and to semi-manually handle change detection (a bit like you would with React). These APIs already…
maximedupre
  • 3,597
  • 4
  • 24
  • 56
10
votes
1 answer

Angular 10 Libraries and IVY/ngcc Compatibility

I have a library that needs to be distributed via npm. The recommendation for Angular 10 still seems to be that such libraries should be compiled with IVY disabled but that the Angular CLI will ensure that the library is still compatible with an…
Matthew Dolman
  • 1,622
  • 6
  • 24
  • 46
10
votes
1 answer

Error: Tried to overwrite .__ivy_ngcc_bak with an ngcc back up file, which is disallowed

I have upgraded from Angular 8 to 9 and have enabled Ivy following all the steps here. When I run npm install a handful of my packages throw the error: Tried to overwrite .__ivy_ngcc_bak with an ngcc back up file, which is…
Kyle Abens
  • 203
  • 2
  • 15
10
votes
4 answers

error NG6002: Appears in the NgModule.imports of , but could not be resolved to an NgModule class

I just updated from Angular 8.2 to 9. Everything works well if I disable ivy, but when it's enabled I'm getting a lot of errors that seems to be kind of obscure, at least I can't find any results when googling it. I'm quite sure I've done everything…
raouaoul
  • 512
  • 2
  • 7
  • 25
10
votes
3 answers

Angular Ivy compiler and webpack

We would like to use the new Angular 8 Ivy compiler with webpack. We don't use Angular CLI. Is this possible? How can this be done? I can't seem to find information regarding this requirement.
stephan.peters
  • 845
  • 8
  • 29
9
votes
1 answer

Angular Library Compile Time Error "Invariant violated: No format-path or format"

I have an Angular 11 project that is trying to integrate SpreadJS Designer, but is failing during the ngcc step Compiling @grapecity/spread-sheets-designer-angular : esm2015 as esm2015 with the exception: Error on worker #3: Error: Invariant…
vicatcu
  • 5,397
  • 5
  • 35
  • 53
9
votes
1 answer

HMR fails with Angular 9 + IVY: Type AppComponent is part of the declarations of 2 modules: AppModule and AppModule

Affected Package HMR + IVY Is this a regression? pre-IVY, it works Description Seems IVY and HMR don't play well together? However I've seen tickets of them that are closed so I suppose it should be possible. I have on re-load after code…
1
2 3
12 13