Looking for lint rule recommendations

Our team currently only has ESLint with default settings. If you have any rules that are useful in practice, please share them. Especially ones that helped cut down code review time.

by 지나가던행인973

8 answers

For real, even just hanging that up makes reviews way easier.

by 초보개발자341 · ▲0

Our team uses eslint-plugin-import to enforce import order, and it definitely reduced the number of things to flag in reviews. But at first everyone found it annoying, so an adjustment period was needed.

by 스타트업러199 · ▲0

Well, I think turning on TypeScript strict should come before adding ESLint rules.

by 지나가던행인622 · ▲0

Do you have a source? Like a post that compiles recommended rules.

by 문과출신개발자779 · ▲0

I limited complexity to 10, and the code is much more readable now. However, there are many places that break when refactoring, so it needs to be discussed and agreed upon before adopting. I'm satisfied.

by 호기심천국428 · ▲0

I'm curious too lol

by 주말개발자854 · ▲0

Using eslint-plugin-import to sort import order pretty much eliminates time spent discussing conventions during code review. Adding sort-keys as well also automates object key organization, which is nice. If the team is small, it settles in quickly.

by 주말개발자343 · ▲0

Actually, adding rules can come at a higher cost to enforce. Especially when team members have inconsistent skill levels, rules tend to cause more conflict. Instead of blindly adding rules just because they're popular, it makes more sense to gauge the team atmosphere first.

by 문과출신개발자523 · ▲0