eslint-plugin-fp-ts
eslint-plugin-fp-ts copied to clipboard
Suggested additional rules
First, thanks for putting together this plugin, I already found a few places in our codebase that were simplified by the usage of this so kudos!
I have some suggestions that could make this even better. These are some common patterns I've seen as a result of refactors or just not paying enough attention:
- Replace map + getOrElse with fold
- Replace chain + lifting return val with map
- e.g.
O.chain(x => O.some(f(x))) ==> O.map(x => f(x))
- e.g.
Additionally, IntelliJ has quite a number of "inspections" for Scala that could be used as inspiration and ported over to this linter.