-
Notifications
You must be signed in to change notification settings - Fork 0
Node
baltasarb edited this page Sep 26, 2018
·
11 revisions
Install express generator globally:
npm install express-generator -g
Display command options with:
npm install express-generator -g
Create the application skeleton with:
express --view=selectedViewEngine appName
To finish, change the directory to appName and run:
npm install
Install esling locally with google configuration:
npm install --save-dev eslint eslint-config-google
Create a configuration file with:
eslint --init
In the .eslintrc file add the rule:
rules: {
'no-console': 'off'
}
Add to .eslintrc file:
"parserOptions": {
"ecmaVersion": 6
}
Or the following which produces the same effect:
"env": {
"es6":true
}
If the following rule is present and the current os is windows:
eslint linebreak-style: ["error", "unix"]
Change to:
eslint linebreak-style: ["error", "windows"]