From 204e5e4ee47f419d0c7d7ab93bf0a0b7c03d2fc0 Mon Sep 17 00:00:00 2001 From: William Boman Date: Mon, 5 Sep 2016 15:59:30 +0200 Subject: [PATCH] lint: default to ecmaVersion: 6, keep ecmaVersion: 5 for client/ --- .eslintrc.yml | 3 +++ package.json | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.eslintrc.yml b/.eslintrc.yml index 971713e2..223901ec 100644 --- a/.eslintrc.yml +++ b/.eslintrc.yml @@ -7,6 +7,9 @@ env: mocha: true node: true +parserOptions: + ecmaVersion: 6 + rules: block-spacing: [2, always] brace-style: [2, 1tbs] diff --git a/package.json b/package.json index 3e7ad02c..8c5e4f26 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,9 @@ "test": "npm-run-all -c test:mocha lint", "test:mocha": "mocha -r test/fixtures/env.js test/**/*.js", "lint": "npm-run-all -c lint:js lint:css", - "lint:js": "eslint .", + "lint:js": "npm-run-all -c lint:js:es5 lint:js:es6", + "lint:js:es5": "eslint --parser-options=\"ecmaVersion:5\" client/", + "lint:js:es6": "eslint --ignore-pattern client/ .", "lint:css": "stylelint \"**/*.css\"", "prepublish": "npm run build" },