Monday 13 March 2017

Package.json file fail to start up lite and type servers - 'iterator' must have identical modifiers - error TS2687

I am setting up my development environment for a tutorial on angular 2 as per this site.

I have followed all the steps up until when we are using a package called concurrently to run the typeserver and the lite server simultaneously.

Here is my package.json file contents:

{
  "name": "ng-start",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "start": "tsc && concurrently \"npm run tsc:w\" \"npm run lite\"",
    "lite": "lite-server",
    "tsc": "tsc",
    "tsc:w": "tsc -w",
    "typings": "typings",
    "postinstall": "typings install"
  },

"keywords": [],
"author": "",
"license": "ISC",
"devDependencies": {
  "concurrently": "^3.4.0",
  "lite-server": "^2.3.0",
  "typescript": "^2.2.1",
  "typings": "^2.1.0"
}

}

running npm start gives me the following error - (I've included some version information at the bottom):

J:\ng-start>npm start

> ng-start@1.0.0 start J:\ng-start
> tsc && concurrently "npm run tsc:w" "npm run lite"

typings/globals/node/index.d.ts(40,14): error TS2687: All declarations of 'iterator' must have identical modifiers.

npm ERR! Windows_NT 10.0.14393
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"
npm ERR! node v6.10.0
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! ng-start@1.0.0 start: `tsc && concurrently "npm run tsc:w" "npm run lite"`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the ng-start@1.0.0 start script 'tsc && concurrently "npm run tsc:w" "npm run lite"'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the ng-start package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     tsc && concurrently "npm run tsc:w" "npm run lite"
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs ng-start
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls ng-start
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     J:\ng-start\npm-debug.log

J:\ng-start>ng --version
'ng' is not recognized as an internal or external command,
operable program or batch file.

J:\ng-start>node --version
v6.10.0

J:\ng-start>lite --version
'lite' is not recognized as an internal or external command,
operable program or batch file.

J:\ng-start>



via Harriet

No comments:

Post a Comment