diff --git a/.eslintignore b/.eslintignore new file mode 100644 index 0000000000..0799652254 --- /dev/null +++ b/.eslintignore @@ -0,0 +1,20 @@ +node_modules/ +public/src/nodebb.min.js +*.sublime-project +*.sublime-workspace +.project +.vagrant +.DS_Store +logs/ +/public/templates +/public/uploads +/public/sounds +/public/vendor +/public/nodebb.min.js +/public/acp.min.js +/public/src/modules/string.js +.idea/ +.vscode/ +*.ipr +*.iws +/coverage diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 0000000000..f8ca19c4cb --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,6 @@ +{ + "rules": { + "handle-callback-err": [ "error", "^(e$|(e|(.*(_e|E)))rr)" ] + } +} + diff --git a/package.json b/package.json index 56323b7773..e581eeb255 100644 --- a/package.json +++ b/package.json @@ -90,6 +90,7 @@ "xregexp": "~3.1.0" }, "devDependencies": { + "eslint": "^3.4.0", "grunt": "~0.4.5", "grunt-contrib-watch": "^1.0.0", "istanbul": "^0.4.2",