Why the adoption of a cross squad/team Code Style Guide is important.
What is the difference between formatting, code conventions and linting.
Why it should not matter what specific standard or Style Guide your team is adopting.
Vs Linting The transformation from one representation of code to another without changing syntax or semantic meaning. It’s the rendering of your code. Formatting 4 What is Code Style Formatting does. A set of guidelines that recommend programming style, practices, and methods for each aspect of a program written in a certain language. Conventions are Review Guidelines. Conventions Conventions encourage. The process of running a program that will analyse code for potential errors. It’s a form of Static Code Analysis. Linting Linting enforces.
• Catch code issues earlier • No more arguing about the colour of the bikeshed • Improves Readability • Improves Interoperability Benefits of common Code Style
Code Style Positive “They're useful for homogenising style across the department, and […] can help reduce more obvious code smells.” Negative “They are draconic and prevent me from writing any code - good or bad.” Action “We should have one, I’m not fussed what’s in it, but it should be universal and enforced!” Uncertainty “Meh, I can see their use, but would be wary of creating one that people adopt, taking a very long time gathering consensus.”
Common Code Style • Do a Survey to identify goals and use cases • Suggest a way forward & discuss it • [Decide on the outcome] 2. Collate, create and provide tooling for integrations • Needs to cover identified goals and use cases 3. Enforce within code base • E.g. add PR feedback or start failing builds