question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Is --create-ivy-entry-points correctly used?

See original GitHub issue

Current Behavior

Currently this script is added

“postinstall”: “ngcc --properties es2015 browser module main --first-only --create-ivy-entry-points”,

when adding something from @nrwl/angular.

However I just noticed this

… If you opt-out of bundling dependencies you will need to run the standalone Angular compatibility compiler (ngcc). This is needed because otherwise Node will be unable to resolve the Ivy version of the packages.

You can run ngcc after each installation of node_modules by adding a postinstall npm script:

// package.json
{
  "scripts": {
    "postinstall": "ngcc"
  }
}

Don’t use --create-ivy-entry-points as this will cause Node not to resolve the Ivy version of the packages correctly.

source

So I was wondering if it being there is correct?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

11reactions
BruneXXcommented, Dec 16, 2020

Hi Guys is not clear to me after read all thread if I need to continue using

ngcc --properties es2015 browser module main --first-only --create-ivy-entry-points

or just:

ngcc

I’m came here after reading the following: Don’t use --create-ivy-entry-points as this will cause Node not to resolve the Ivy version of the packages correctly.

from the angular documentation https://angular.io/guide/ivy but is not clear to me what I need to do in the latest angular version (11.0.4)

Please can anyone clarify?

Thanks!

7reactions
ranyehushuacommented, May 19, 2020

@brandonroberts I am having trouble understanding, so you are saying that running "postinstall": "ngcc --properties es2015 browser module main --first-only --create-ivy-entry-points" is still permissible? or are you saying we should follow the docs and not run with the --create-ivy-entry-points flag? Thanks very much!

Read more comments on GitHub >

github_iconTop Results From Across the Web

What are the reasons for adding angular postinstall "ngcc ...
The create-ivy-entry-points will tell ngcc to create new properties for the Ivy generated entry, instead of overwriting the previous one.
Read more >
nrwl-nx/community - Gitter
works fine, i just had to remove: "postinstall": "ngcc --properties es2015 browser module main --first-only --create-ivy-entry-points" from my package.json.
Read more >
Angular 9: 5 things we did when we upgraded - Medium
It turns out that Ivy, was not ready yet to perform parallel builds, which we do in our pipelines.
Read more >
Building an Angular Library with multiple entry points | Articles
An Angular library lets you share code between multiple projects. For a larger library it's recommended to use subentry points. We'll build a ......
Read more >
Creating libraries - Angular
For publishing to npm use the partial-Ivy format as it is stable between patch versions of Angular. Avoid compiling libraries with full-Ivy code...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found