-
-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
eslint: fixes linebreak-style bug in eslint
- Loading branch information
Showing
1 changed file
with
24 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,31 @@ | ||
// http://eslint.org/docs/user-guide/configuring | ||
|
||
const rules = { | ||
'no-underscore-dangle': ['error', { | ||
allowAfterThis: true, | ||
enforceInMethodNames: false, | ||
// node-ignore only | ||
allow: ['_rules', '_test'] | ||
}], | ||
|
||
'operator-linebreak': 0, | ||
|
||
indent: ['error', 2, { | ||
MemberExpression: 0, | ||
|
||
// Eslint bug | ||
ignoreComments: true | ||
}] | ||
} | ||
|
||
if (process.platform === 'win32') { | ||
// Ignore linebreak-style on Windows, due to a bug of eslint | ||
rules['linebreak-style'] = 0 | ||
} | ||
|
||
module.exports = { | ||
// Uses `require.resolve` to support npm linked eslint-config | ||
extends: require.resolve('eslint-config-ostai'), | ||
root: true, | ||
rules: { | ||
'no-underscore-dangle': ['error', { | ||
allowAfterThis: true, | ||
enforceInMethodNames: false, | ||
// node-ignore only | ||
allow: ['_rules', '_test'] | ||
}], | ||
|
||
'operator-linebreak': 0, | ||
|
||
indent: ['error', 2, { | ||
MemberExpression: 0, | ||
|
||
// Eslint bug | ||
ignoreComments: true | ||
}] | ||
} | ||
rules | ||
} |