eslint-plugin-flowtype
eslint-plugin-flowtype copied to clipboard
feat: add support for enum type
Add support for the enum type usage https://flow.org/en/docs/enums/.
Fixes https://github.com/gajus/eslint-plugin-flowtype/issues/502.
Something I found during the tests, if you use @babel/plugin-syntax-flow plugin, then the babel-plugin-transform-flow-enums plugin must be placed before @babel/plugin-syntax-flow, otherwise the parser won't recognize the enum type. But, I think you could even remove @babel/plugin-syntax-flow if you are using babel-plugin-transform-flow-enums.
hey @gajus, when you have some time, could you please check this PR? thanks 🙇
Closing this in favor of https://github.com/flow-typed/eslint-plugin-ft-flow which has implemented it already