I downloaded the Ionic project template, followed the instructions:
-
Copy this project directory
-
Install Ionic, cordova and node_modules
But when I try to use ionic serve or run the emulator I get TypeScript errors
I solved the initial problems installing the latest Typescript version (2.9.2) but then I got these new errors:
Typescript Error
Class ‘NavControllerBase’ incorrectly implements interface ‘NavController’. Types of property ‘popTo’ are incompatible. Type ‘(indexOrViewCtrl: any, opts?: NavOptions, done?: Function) => Promise’ is not assignable to type ‘(page: any, params?: any, opts?: NavOptions, done?: Function) => Promise’. Types of parameters ‘done’ and ‘opts’ are incompatible. Type ‘NavOptions’ is not assignable to type ‘Function’. Property ‘apply’ is missing in type ‘NavOptions’.
and
Typescript Error
Class ‘Subject<T>’ incorrectly extends base class ‘Observable<T>’. Types of property ‘lift’ are incompatible. Type ‘<T, R>(operator: Operator<T, R>) => Observable<T>’ is not assignable to type ‘<R>(operator: Operator<T, R>) => Observable<R>’. Type ‘Observable<T>’ is not assignable to type ‘Observable<R>’. Type ‘T’ is not assignable to type ‘R’.
Can you please help me?