Recently I’ve updated to ionic rc0. since then I see there is no typings folder or typings.json . The upgrade phase at link here step 26 specifies that typings folder and json should be removed , after I removed it in webstorm all Promise types are changed to red indicating that the type is not defined , sorry to tell that I see no documentation regarding this .
If you can please answer this question regarding promise not found . stackoverflow
all the places where there is “Promise” I get it in red for the IDE can’t recognize this type , bare in mind I deleted (as instructed by ionic2 rc0 upgrade ) the typings folder and json .
Your code works for me, but I’m on rc1. Maybe there is a difference, I don’t know, but try with rc1, there is no big change between rc0 and rc1 (unlike beta.11 and rc0).
I have webstorm , but as I see it the project has no definition for “Promise” , how did your IDE identifies the “Promise” definition ? or if you click on “Promise” to check definition ( go to definition ) does it shows you the def ? you see the problem is that def needs to come from some source ( d.ts file or js ) and since ionic2 rc1 removed the typings folder I don’t understand how they want types like “Promise” to be defined .
Same here, I manually changed webstorm to point to the local Typescript libs 2.0.3 and nothing changed.
If I add es6 promise typing the compiler complaints about duplicated definitions.
UPDATE: Changing JavaScript to ECMAScript 6 fixes the problem.