Angular library build error with enableIvy=false
See original GitHub issueType of Issue
[x ] Bug Report
[ ] Feature Request
Description
In my project , I set up “enableIvy”: false would be error. If I replacing “enableIvy”: false with “compilationMode”: “partial” , it can work normally, but I don’t know why
How To Reproduce
my test project: https://github.com/yinshuxun/test-ngpackager
git clone https://github.com/yinshuxun/test-ngpackager.git
yarn
yarn build
Expected Behaviour
Version Information
$ node_modules/.bin/ng-packagr --version
ng-packagr: 12.2.0
@angular/compiler: 12.2.1
rollup: 2.56.2
typescript: 4.3.5
Please include all version numbers that might be relevant, e.g. third-party libraries
Issue Analytics
- State:
- Created 2 years ago
- Comments:12 (5 by maintainers)
Top Results From Across the Web
Compiling an Angular 9 library with enableIvy: false gives an ...
The problem was that public-api.ts in otherlib was exporting the folder, not the barrel file (index). So I changed export * from "./lib";....
Read more >Upcoming improvements to Angular library distribution
ngcc is our way to compile View Engine libraries so that Ivy ... which allows us to remove the --enableIvy flag and deprecate...
Read more >Understanding Angular Ivy Library Compilation | lacolaco/tech
Here is the main topic. First, let's look at compiling libraries with enableIvy: false , which is the current recommended setting for v11....
Read more >Angular Ivy
CLI commands run ngcc as needed when performing an Angular build. ... The following example shows how to set the enableIvy option to...
Read more >Newest 'angular-ivy' Questions - Stack Overflow
Angular app build time is taking too long after importing an library ... set in an angular library: "angularCompilerOptions": { "enableIvy": false }...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
That’s our internal package, so the whole source code can not be provided.
That’s OK you won’t help, let’s wait for other active maintainers.
Besides, we’ve already found a workaround by a custom tsconfig like following as Angular document.
@yinshuxun, that is not a reproduction, you are only re-exporting a closed source library.
And that one has quite a few dependencies, some of which are Angular libraries. You should add a 2nd minimal example library that can trigger the same issue when being re-exported, otherwise we can’t really help you with anything. We need to see the full code and you should work on providing a minimal reproduction, we can’t and won’t review tens of libraries for you.