phenomnomnominal / angular-2-local-storage

LocalStorageService for Angular 2 with the same API as angular-local-storage
MIT License
93 stars 49 forks source link

Metadata version mismatch node_modules/angular-2-local-storage/dist/notify-options.interface.d.ts, found version 4, expected 3 #57

Open kdiggle opened 6 years ago

kdiggle commented 6 years ago

When running ng build -prod I am getting this exception using the latest version of the angular-2-local-storage.

If I install the previous version 1.0.1 I don't have any issues?

Canadadry commented 6 years ago

Same here, with angular4 I have can't run ng build --prod nor ng serve

ALMONLU commented 6 years ago

How to resolve this problem?

phenomnomnominal commented 6 years ago

Different versions of the Angular compiler generate different versions of the required metadata. I guess you need to match the right versions of the lib with the right versions of @angular/cli?

ALMONLU commented 6 years ago

I don't know what versions of @angular/cli is right to match.Do you know?

my package.json: "angular-2-local-storage": "^1.0.1",

"@angular/cli": "^1.7.4", "@angular/compiler-cli": "4.1.3",

phenomnomnominal commented 6 years ago

Latest versions of everything should work together, otherwise, I’m not sure.

Canadadry commented 6 years ago

You must choose the good version in your package.json is solved it this way

ALMONLU commented 6 years ago

I've tried to use the latest version,, but it has not been solved. Thank you for your advise, i will try again.

ALMONLU commented 6 years ago

The versions of @angular/cli or the versions of angular-2-local-storage?