From 1e52df9a205612028ce49b60a4e888bfa1ea548e Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Fri, 1 Nov 2024 22:39:28 +0000 Subject: [PATCH] Add daily email for 2024-10-30 Code reviews are about the code, not code style --- source/_daily_emails/2024-10-30.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 source/_daily_emails/2024-10-30.md diff --git a/source/_daily_emails/2024-10-30.md b/source/_daily_emails/2024-10-30.md new file mode 100644 index 00000000..aa0c1ea1 --- /dev/null +++ b/source/_daily_emails/2024-10-30.md @@ -0,0 +1,21 @@ +--- +title: Code reviews are about the code, not code style +date: 2024-10-30 +permalink: daily/2024/10/30/code-reviews-are-about-the-code-not-code-style +tags: + - software-development +cta: ~ +snippet: | + If you do code reviews, they should be about reviewing the code itself and not about the style of the code. +--- + + +If you do code reviews, they should be about reviewing the code and not about the style of the code. + +There shouldn't be comments about whether tabs or spaces are used, how many spaces are on each line, where the braces are, or whether there should be semicolons. + +A code style should be defined upfront and checking code against it can be done automatically with tools such as phpcs or Prettier. + +You don't need to wait for a human to review the code style - automated tools can be run locally or in a CI pipeline and provide feedback much faster. + +And if people aren't reviewing the code style, they can focus on reviewing the code itself.