-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
add eslint rules from fbjs #202
Conversation
5b0bb2f
to
ed4921e
Compare
node_modules/ | ||
lib/ | ||
scripts/ | ||
# for disable website but should be done as well |
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.
Do you mean something like this?
# TODO: Enable ESLint for website.
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.
@yungsters haha! yeah that's what I meant, not sure my comment is even in English lol
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.
oh it was supposed to be "for now... "
Here are the "undefined" identifiers:
I think we should just define these as globals in |
Yea, you can define them here for now. They should make their way back to fbjs (and there are probably other ones that we should just copy over from flow). We have them defined internally, I just went for the minimal sync. |
5bb3986
to
ddb827a
Compare
@zpao should be good |
ddb827a
to
c773b84
Compare
e9709ee
to
8d2b851
Compare
scripts/ | ||
# for disable website but should be done as well | ||
website/ | ||
*.md |
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.
When you update the comment, can you also add a newline at the end of the file? Makes life easier (internally, we have lints that try to automatically add these).
@yungsters done, the tests are failing but not sure why, haven't done any changes to |
👍 thanks! We'll go through the land internally and merge out process, should be all wrapped up soon. |
a7e8108
Summary: As @zpao suggested (reference #58) here is the new PR with the rules from [facebook/fbjs#49](facebook/fbjs#49). I'll still need some guidance on what should be Relay specific. At the moment with the current fbjs rules there is a lot of errors on [no-undef](http://eslint.org/docs/rules/no-undef.html) (example: $FlowIssue, $FixMe, $Enum and also when defining Flow types, this is related to [babel-eslint/known-issues](https://github.com/babel/babel-eslint#known-issues) - [babel-eslint#130](babel/babel-eslint#130) and [babel-eslint#132](babel/babel-eslint#132)) @josephsavona @zpao what are your thoughts? Closes #202 Reviewed By: @josephsavona Differential Revision: D2417828
As @zpao suggested (reference #58) here is the new PR with the rules from facebook/fbjs#49.
I'll still need some guidance on what should be Relay specific.
At the moment with the current fbjs rules there is a lot of errors on no-undef (example: $FlowIssue, $FixMe, $Enum and also when defining Flow types, this is related to babel-eslint/known-issues - babel-eslint#130 and babel-eslint#132)
@josephsavona @zpao what are your thoughts?