Skip to content
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

Pull in Flow-specific rules from eslint-plugin-babel #141

Closed
taion opened this issue Oct 24, 2016 · 4 comments
Closed

Pull in Flow-specific rules from eslint-plugin-babel #141

taion opened this issue Oct 24, 2016 · 4 comments

Comments

@taion
Copy link

taion commented Oct 24, 2016

Ref #40 (comment), babel/eslint-plugin-babel#93 (comment)

In addition to the obvious babel/flow-object-type, the following rules in eslint-plugin-babel:

  • babel/array-bracket-spacing
  • babel/arrow-parens

Only make a difference now when using Flow. (The latter because ESLint now supports async/await natively)

I think it would make sense to pull in those rules here – I found it confusing that the rule I wanted to get rid of spurious warnings on arrow parens when using type annotations was in eslint-plugin-babel rather than here.

@danharper
Copy link
Collaborator

Hm, I'm kind of unsure about the others.

I see this plugin as providing lint rules specific to Flow's syntax, whereas eslint-plugin-babel provides replacement rules to the core ESLint ones until the proposal reaches stage 4.

Since ESLint is now officially supporting simple type annotations in the AST, those 2 rules can probably be upstreamed back to ESLint.

@taion
Copy link
Author

taion commented Oct 24, 2016

Ah, I didn't know that. Thanks.

@taion taion closed this as completed Oct 24, 2016
@danharper
Copy link
Collaborator

Looks like there's a PR open for arrow-parens too :) eslint/eslint#7436

@taion
Copy link
Author

taion commented Oct 24, 2016

Thanks. I opened eslint/eslint#7445 to fix array-bracket-spacing as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants