Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ng9 IVY Ng2-odometer library issue when compile with AoT #10

Open
LanderBeeuwsaert opened this issue Feb 7, 2020 · 2 comments
Open

Comments

@LanderBeeuwsaert
Copy link

See the ticket on the angular github as well:
angular/angular#35203

Affected Package
The issue is caused by package @angular/....
Is this a regression?
Sort of, it's because of IVY + AoT + https://github.com/jmandreslopez/ng2-odometer

it works with NG8 + AoT

Description
A clear and concise description of the problem...
Sooooo, upgrade to NG9 took some time but eventually I got there.
Development works when I use the settings:
"optimization":false,
"sourceMap":true,
"extractCss":true,
"namedChunks":false,
"aot":false,
"extractLicenses":false,
"vendorChunk":false,
"buildOptimizer":false,

When I set
"aot":true
It doesn't

error message is:
ERROR in node_modules/ng2-odometer/dist/index.d.ts:3:23 - error NG6005: Ng2OdometerModule.forRoot returns a ModuleWithPro
viders type without a generic type argument. Please add a generic type argument to the ModuleWithProviders type. If this
occurrence is in library code you don't control, please contact the library authors.
3 static forRoot(): ModuleWithProviders;

I already have an old issue open on the library in respect to IVY:
#8
but nobody's home it seems ;).

I seem to remember the angular team was trying to be compatible with as much libraries as possible for IVY, not sure if that is still relevant/the case.

On first look, IVY is crazy fast in comparison to viewEngine for our application. Well done!

Best regards,

Lander

@arin-pang
Copy link

I forked this repo and fixed this issue. (https://github.com/arin-pang/ng9-odometer)

@muzyka-viacheslav
Copy link

I forked this repo and fixed this issue. (https://github.com/arin-pang/ng9-odometer)

You are a saver man, thanks for this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants