loiane / angular2-crud-rest

Sample Angular (2.x and 4.x) app: CRUD example + routing
145 stars 90 forks source link

SyntaxError: Use of const in strict mode. #2

Closed jepster closed 7 years ago

jepster commented 7 years ago

I have downloaded the zip archive from your project, unpacked it and run "ng serve" in the directory. Afterwards I am getting this error:

peter@DESKTOP-UNMGSSF:/mnt/c/Users/peter/Dev/angular2-crud-rest-master$ ng serve

/home/peter/lib/node_modules/@angular/cli/bin/ng:7 const CliConfig = require('../models/config').CliConfig; ^^^^^ SyntaxError: Use of const in strict mode. at Module._compile (module.js:439:25) at Object.Module._extensions..js (module.js:474:10) at Module.load (module.js:356:32) at Function.Module._load (module.js:312:12) at Function.Module.runMain (module.js:497:10) at startup (node.js:119:16) at node.js:902:3 peter@DESKTOP-UNMGSSF:/mnt/c/Users/peter/Dev/angular2-crud-rest-master$

loiane commented 7 years ago

Hi, updated the project to the latest Angular CLI and Angular 4.x RC.5. Error should be fixed.