I am having issue while running react-xp for web.i get this error message while running "Cannot find name 'Promise'".Thanks in advance Please check github issue here react-xp issue
Asked
Active
Viewed 214 times
0
-
1Did you install all the dependencies? Did you require `Promise` where you're using it? – Shaharyar Apr 19 '17 at 06:32
2 Answers
2
You should install required packages beforehand. Simply install following two packages first.
npm install --save-dev @types/es6-promise
npm install --save-dev @types/es6-collections
Then add corresponding type information to react-native.d.ts
file as below.
/// <reference path="../../node_modules/@types/es6-promise/index.d.ts" />

Izzet Yildirim
- 640
- 1
- 11
- 19
0
This is how I fixed my problem very similar to this one
https://github.com/dabit3/create-xp-app/issues/2
inside your tsconfig.json
file in the root folder, change:
..."compilerOptions": { "target": "es5", ...
change the es5
-> es6

ey dee ey em
- 7,991
- 14
- 65
- 121