I have a project I have been building from the "Getting started" project 
found on Angular.io.  As I've been making changes, I've been making 
comments throughout the code as I've been learning (to remind myself).  I 
have now copied the project to a different computer to continue working on 
it, and I get an error when I run "npm run tsc" to transpile my ts --> js.

The error is complaining about a block comment I put in my tsconfig.json 
file.  I have since learned that comments are not valid for a JSON file, so 
I'm taking it out.  *My question is not about why I was getting an error 
with comments in my JSON, but rather how I can find out why I'm getting two 
different behaviors from two different systems - *I'm confused as to why 
this was working on my other computer but not on this one.  Both systems 
are Windows 10 computers, running the same versions of node, npm, and tsc 
(dunno why npm would matter, but I'm confused so I'm checking everything I 
can think of).

Here are the versions I am using:

C:\...\>node -v
v6.9.4


C:\...\>npm -v
3.10.10


C:\...\>tsc -v
Version 2.1.5

When I run "npm run tsc" I get a successful compile on my old system, but 
on the new system I get the following:


C:\...\>npm run tsc


> [email protected] tsc C:\...\
> tsc


error TS5014: Failed to parse file 'tsconfig.json': Unexpected token / in 
JSON at position 400.


npm ERR! Windows_NT 10.0.10586
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program 
Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "tsc"
npm ERR! node v6.9.4
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! [email protected] tsc: `tsc`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] tsc script 'tsc'.
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 angular-quickstart 
package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     tsc
npm ERR! You can get information on how to open an issue for this project 
with:
npm ERR!     npm bugs angular-quickstart
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls angular-quickstart
npm ERR! There is likely additional logging output above.


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


I have checked the project folders between the two systems and the files 
are indeed identical.  I have also checked line endings (CRLF <----> CR) 
just in case tsc was treating them different between systems, but no, they 
are the same on both systems.

Any ideas what else to check?

-- 
You received this message because you are subscribed to the Google Groups 
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to