Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upSupport for flow syntax extensions. #592
Comments
jprichardson
added
the
question
label
Aug 18, 2016
This comment has been minimized.
This comment has been minimized.
|
You can, just use the |
jprichardson
closed this
Aug 18, 2016
This comment has been minimized.
This comment has been minimized.
|
So I run into following issue gajus/eslint-plugin-flowtype#72 when using standard with |
This comment has been minimized.
This comment has been minimized.
|
Also babel/babel-eslint#293 seems relevant here. |
This comment has been minimized.
This comment has been minimized.
|
@Gozala Are you specifying the flowtype plugin in your {
"standard": {
"plugins": ["flowtype"]
}
}Setting a custom parser and plugins are the only ways you can try to solve this issue with If you require enabling extra rules from the flowtype plugin and/or disabling rules in |
This comment has been minimized.
This comment has been minimized.
|
@feross Yeap that is pretty much what I use: {
"standard": {
"parser": "babel-eslint",
"plugins": [
"flowtype"
]
}The problem as described in babel/babel-eslint#293 is that babel-eslint does not seem to have a way of informing eslint that type import is different from value import & there for eslint will report duplicate imports.
That is what I end up doing for now, but I would much rather not do that. Maybe standard could avoid this issue by using import/no-duplicates instead of stock no-duplicates ? |
This comment has been minimized.
This comment has been minimized.
|
The import plugin actually looks really well done. Adding another eslint plugin is not ideal for running time, but if there are other rules in there that would make |
This comment has been minimized.
This comment has been minimized.
@feross I believe it primary selling point is:
Also should I open new issue regarding duplicate imports issue caused by |
This comment has been minimized.
This comment has been minimized.
Would not it be reasonably to allow configuring those plugins ? It would not solve the duplicate imports issue I'm afraid, but I did also notice that I'm unable to configure |
This comment has been minimized.
This comment has been minimized.
|
Created a separate issue in regards to |
This comment has been minimized.
This comment has been minimized.
This is a slippery slope. When you see If you really want a flow-type variant of |
This comment has been minimized.
This comment has been minimized.
Thanks. I have followed this advice and created https://github.com/Gozala/standard-flow and https://github.com/Gozala/eslint-config-standard-flow to add flow support and lint type annotations with the same rules as rest of the code. |
This comment has been minimized.
This comment has been minimized.
ArmorDarks
commented
Mar 19, 2017
|
I think that forcing forks is terrible idea, because they almost always lags behind main library and ends up unmaintained. |
Gozala commentedAug 18, 2016
Is there way to support flow syntax extensions for projects that want to use that ?