From fb566152b7372d2d4890b8cfe569da84e4be377e Mon Sep 17 00:00:00 2001 From: Luke Childs Date: Mon, 30 May 2016 22:14:25 +0100 Subject: [PATCH] Add linting --- .travis.yml | 2 +- package.json | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index d9547de..4af4e54 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,4 @@ language: node_js node_js: node -script: npm run test +script: npm run lint && npm run test after_success: npm run coverage diff --git a/package.json b/package.json index f87eb41..7c8f6e7 100644 --- a/package.json +++ b/package.json @@ -10,6 +10,7 @@ "build:map": "babel --source-maps=true -d dist src", "pretest": "npm run build:map", "test": "nyc ava test", + "lint": "eslint src", "coverage": "nyc report --reporter=text-lcov | coveralls", "prepublish": "npm run build" }, @@ -21,6 +22,9 @@ "add-module-exports" ] }, + "eslintConfig": { + "extends": "lukechilds" + }, "repository": { "type": "git", "url": "git+https://github.com/lukechilds/node-browser-environment.git" @@ -47,6 +51,8 @@ "babel-plugin-add-module-exports": "^0.2.1", "babel-preset-es2015": "^6.9.0", "coveralls": "^2.11.9", + "eslint": "^2.11.1", + "eslint-config-lukechilds": "^1.2.1", "nyc": "^6.4.4" } }