Photo by Alev Takil on Unsplash
Hello,
I'm struggling a lot with this theme. I'm kind feeling that I'm the snotty sheep that blocks every PR because the code is not well formatted, there are some css files that need some improvements among other complex things.
I would like to know how critical are you when doing pull request reviews.
When do you consider that a PR should have the tag of 'needs work'?
Do you block a PR if it contains CSS files improvements to be done?
How do you feel when you see extra lines that are not needed on the code.
When should we stop to being too much picky?
This are some questions than I'm confronted with, and seems that this is not so important for others.
Thanks in advance for spending time to read my blog and answer of the following questions.
Top comments (4)
Automate everything. IMO code reviews shine when we discuss design decisions, thought process and possible edge scenarios. Formatting should be pointed out by a bot.
Thanks Gayan , very interesting what you said. I never thought in doing it. Can you share something about it?
For an instance for code style checks I use prettifier, PHP code sniffer, etc
In your case you might be able to find a decent linter for the style rules you want in the code base.
Githubs super linter has support for most languages. And there is also a GitHub action that will help you automate this process. This would be a good starting point.
github.com/github/super-linter
Thanks 👍