Cannot find name 'LocalForage'. #74

Closed
phillipzada opened this Issue Feb 8, 2017 · 9 comments

Comments

Projects
None yet
8 participants
@phillipzada

Since updating the package getting this error

Typescript Error

Cannot find name 'LocalForage'.

.../node_modules/@ionic/storage/es2015/storage.d.ts
undefined
undefined

"@ionic/storage": "^1.1.8"
Ionic Framework: ^2.0.0
Ionic Native: ^2.5.1
Ionic App Scripts: 1.0.1
Angular Core: ^2.4.6
Angular Compiler CLI: ^2.4.6
Node: 6.3.0
OS Platform: Windows 10
Navigator Platform: Win32
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36

@zarko-tg

This comment has been minimized.

Show comment
Hide comment
@zarko-tg

zarko-tg Feb 14, 2017

This is an issue that came with 1.1.8 and only on Windows OS as far as I can tell.

This is an issue that came with 1.1.8 and only on Windows OS as far as I can tell.

@chrisworrell

This comment has been minimized.

Show comment
Hide comment
@chrisworrell

chrisworrell Feb 16, 2017

kinda wondering when they will respond to this, i have tried everything to get it working, im stuck on 1.1.7. i've tried a fresh wipe of my node_modules and reinstall and it appears there is an issue between the dependencies with 1.1.8 and the localforage version, what issue that is though is outside of my ability to see easily

kinda wondering when they will respond to this, i have tried everything to get it working, im stuck on 1.1.7. i've tried a fresh wipe of my node_modules and reinstall and it appears there is an issue between the dependencies with 1.1.8 and the localforage version, what issue that is though is outside of my ability to see easily

@phillipzada

This comment has been minimized.

Show comment
Hide comment
@phillipzada

phillipzada Feb 16, 2017

No idea, but this is a breaking change so I don't know why they haven't responded at least 😢

No idea, but this is a breaking change so I don't know why they haven't responded at least 😢

@Flink91

This comment has been minimized.

Show comment
Hide comment
@Flink91

Flink91 Feb 18, 2017

Same problem with 1.1.8. I had to downgrade as well for now.
(npm install --save @ionic/storage@1.1.7)

Flink91 commented Feb 18, 2017

Same problem with 1.1.8. I had to downgrade as well for now.
(npm install --save @ionic/storage@1.1.7)

@jsayol

This comment has been minimized.

Show comment
Hide comment
@jsayol

jsayol Feb 20, 2017

I've been doing some digging and I'm pretty sure the 1.1.8 version was generated using the --noResolve TS option. Because of this, the generated storage.d.ts file lacks the reference to the LocalForage types that was present in previous versions:

/// <reference types="localforage" />

The code here on github doesn't match the one published on npm though, so I can't really tell for sure nor create a PR to fix it.

cc @mlynch @danbucholtz

jsayol commented Feb 20, 2017

I've been doing some digging and I'm pretty sure the 1.1.8 version was generated using the --noResolve TS option. Because of this, the generated storage.d.ts file lacks the reference to the LocalForage types that was present in previous versions:

/// <reference types="localforage" />

The code here on github doesn't match the one published on npm though, so I can't really tell for sure nor create a PR to fix it.

cc @mlynch @danbucholtz

@mlynch

This comment has been minimized.

Show comment
Hide comment
@mlynch

mlynch Feb 20, 2017

Member

Thanks for the heads up. @danbucholtz seems related to your 1.1.8 release?

Member

mlynch commented Feb 20, 2017

Thanks for the heads up. @danbucholtz seems related to your 1.1.8 release?

@danbucholtz

This comment has been minimized.

Show comment
Hide comment
@danbucholtz

danbucholtz Feb 20, 2017

Contributor

I'll check it out on Windows. It's working great for me on Mac with AoT and non-AoT builds.

Thanks,
Dan

Contributor

danbucholtz commented Feb 20, 2017

I'll check it out on Windows. It's working great for me on Mac with AoT and non-AoT builds.

Thanks,
Dan

@danbucholtz

This comment has been minimized.

Show comment
Hide comment
@danbucholtz

danbucholtz Feb 20, 2017

Contributor

This is fixed in 1.1.9. It seems like the issue was because we had a ^ dependency on TypeScript which changed the way .d.ts files are published. Hard-coding TypeScript 2.0.x fixed the issue for me.

Thanks,
Dan

Contributor

danbucholtz commented Feb 20, 2017

This is fixed in 1.1.9. It seems like the issue was because we had a ^ dependency on TypeScript which changed the way .d.ts files are published. Hard-coding TypeScript 2.0.x fixed the issue for me.

Thanks,
Dan

@longzheng

This comment has been minimized.

Show comment
Hide comment
@longzheng

longzheng Feb 28, 2017

This is not fixed for me in 1.1.9 (on Windows)

I still see /// <reference types="localforage" /> in my storage.d.ts

My package.json has

    "@ionic/storage": "1.1.9",

longzheng commented Feb 28, 2017

This is not fixed for me in 1.1.9 (on Windows)

I still see /// <reference types="localforage" /> in my storage.d.ts

My package.json has

    "@ionic/storage": "1.1.9",
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment