-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ESLint everywhere #40
Conversation
package.json
Outdated
@@ -27,24 +28,19 @@ | |||
"peerDependencies": { | |||
"eslint-plugin-mocha": "^2.0.0", | |||
"eslint-plugin-react": "^4.1.0", | |||
"eslint-plugin-json": "^1.2.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These files should become dependencies instead of peer or devDependencies as our configuration extend these files. See #31
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was following the pattern established in airbnb/javascript
for peerDependencies
.
... puts on thinking cap ...
If we want to be backwards compatible for both npm@2
AND npm@3
then I think we need to keep these in peerDependencies
(but obviously make them more liberal – like "*"
). If we want to only support npm@3
then we can keep them as dependencies
since they will be flattened by default.
Another option (which I have NO idea will work) is to use the require.resolve
pattern used for "extends"
for "plugins"
. i.e. change:
{
plugins: ['mocha', 'json'],
}
to use require.resolve
:
{
plugins: ['eslint-plugin-mocha', 'eslint-plugin-json']
.map(require.resolve),
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a side note I am definitely all for maintaining backwards compatibility. Option 2 is definitely an unknown.
👏 Thanks for the work @indexzero! Looks great! |
👍 great work! |
👍 |
… note of the last few auto-fix differences.
…5. This aligns with future usage of `babel/no-invalid-this`. Fixes #39.
… from which called before forcing config CLI argument passed to `eslint` in `eslint-godaddy**` commands.
…es are published.
This PR removes
jscs
and replaces all rules witheslint
auto-fix. Seejscs
toeslint
research. Since this now uses a single platform,fashion-show
is no longer necessary.The new API surface area is three
eslint-config-**
packages:eslint-config-godaddy
: Base configuration for non-React, ES6 JavaScript applicationseslint-config-godaddy-react
: Configuration for ES6 React JavaScript applicationseslint-config-godaddy-es5
: Configuration for React and non-React ES5 JavaScript applications.