Skip to content
This repository has been archived by the owner on Feb 17, 2021. It is now read-only.

Commit

Permalink
Fix the eslint config when using the CLI (#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
iamlacroix committed Apr 26, 2017
1 parent b93a7d9 commit 8c7434c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/react-scripts/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@trunkclub/build",
"version": "6.1.0",
"version": "6.1.1",
"upstream-version": "0.8.4",
"description": "Configuration and scripts for Create React App. Fork maintained by Trunk Club",
"repository": "trunkclub/create-react-app",
Expand Down
6 changes: 6 additions & 0 deletions packages/react-scripts/scripts/lint.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ var config = require('@trunkclub/eslint-config');
config.fix = true;
config.extensions = ['.js', '.jsx', '.es6'];

// CLIEngine env config differs from .eslintrc
// http://eslint.org/docs/developer-guide/nodejs-api#cliengine
config.envs = Object
.keys(config.env)
.filter(envKey => config.env[envKey])

var eslint = new CLIEngine(config);

var report = eslint.executeOnFiles([paths.appSrc]);
Expand Down

0 comments on commit 8c7434c

Please sign in to comment.