{"id":11294,"date":"2021-12-23T10:00:00","date_gmt":"2021-12-23T01:00:00","guid":{"rendered":"https:\/\/www.gigas-jp.com\/appnews\/?p=11294"},"modified":"2021-12-22T18:37:15","modified_gmt":"2021-12-22T09:37:15","slug":"4-reasons-why-we-need-code-reviews","status":"publish","type":"post","link":"https:\/\/www.gigas-jp.com\/appnews\/archives\/11294","title":{"rendered":"4 Reasons Why We Need Code Reviews"},"content":{"rendered":"\n<p>Code reviews are necessary as they offer multiple benefits that help improve your code and your team. These benefits include:<\/p>\n\n\n\n<ul><li>Helping reduce bugs and logic errors<\/li><li>Providing an opportunity for training<\/li><li>Spreading knowledge across areas and teams<\/li><li>Revealing new ideas and techniques<\/li><\/ul>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Code reviews help reduce bugs and logic errors<\/strong><\/p>\n\n\n\n<p>One of the main things a reviewer should be looking for when reviewing code is that the code does the right thing without any errors.<\/p>\n\n\n\n<p>It may seem like it would be hard to find bugs while reading code, but as developers become more experienced reviewing code, issues will start to stand out.<\/p>\n\n\n\n<p>Even with QA and automated testing, finding bugs during a code review is helpful. Reviews help verify the code and tests are both correct. A code review can direct the developer to the exact area of the problem, making it easier to debug and fix. Reviews are just one more step we can use to help avoid stressful after hour bugs.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Reviews offer opportunities for training<\/strong><\/p>\n\n\n\n<p>We all know how quickly the technology around us changes.&nbsp;there is a new language, tool, or framework every day. We also learn new best practices, standards, and ways to do things as we gain more experience.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>How do we keep all the developers on the team up to date with these changes? Of course, there are courses, tutorials, blogs, the team wikis, and guides out there. But do we have time for every developer on our team to always go through a course? Developers should continue to use these resources and learn from them.&nbsp; However, none of these resources have come close to what we learned by working with the team and having code reviewed. Good code has come from code reviews.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Code reviews spread knowledge across areas and teams<\/strong><\/p>\n\n\n\n<p>If we had two teams of developers who always worked together and reviewed each other\u2019s code versus two groups of developers who never reviewed the other team\u2019s code, who do you think will have better code in the long run?<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>It probably will be the teams that review each other\u2019s code. Those two teams will be passing knowledge back and forth about their specific areas and the best way to do things. They will be learning from different experiences and projects.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Code reviews also reveal new ideas and techniques<\/strong> <\/p>\n\n\n\n<p>Reviews will teach the same team new things the same way they will teach multiple teams. But new ideas and techniques often come up in code reviews even among the same team members.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>Think about most of the code we write. How often do we research different design patterns, consider different architectures or attempt multiple solutions before deploying code? At most places, we don\u2019t have the time to pair program on everything or always meet about how to code every feature. Once a team implements a review process, these suggestions happen without extra steps.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>Tsuki<\/p>\n<div class='wp_social_bookmarking_light'>\n            <div class=\"wsbl_google_plus_one\"><g:plusone size=\"medium\" annotation=\"none\" href=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/11294\" ><\/g:plusone><\/div>\n            <div class=\"wsbl_hatena_button\"><a href=\"\/\/b.hatena.ne.jp\/entry\/https:\/\/www.gigas-jp.com\/appnews\/archives\/11294\" class=\"hatena-bookmark-button\" data-hatena-bookmark-title=\"4 Reasons Why We Need Code Reviews\" data-hatena-bookmark-layout=\"standard\" title=\"\u3053\u306e\u30a8\u30f3\u30c8\u30ea\u30fc\u3092\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306b\u8ffd\u52a0\"> <img src=\"\/\/b.hatena.ne.jp\/images\/entry-button\/button-only@2x.png\" alt=\"\u3053\u306e\u30a8\u30f3\u30c8\u30ea\u30fc\u3092\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306b\u8ffd\u52a0\" width=\"20\" height=\"20\" style=\"border: none;\" \/><\/a><script type=\"text\/javascript\" src=\"\/\/b.hatena.ne.jp\/js\/bookmark_button.js\" charset=\"utf-8\" async=\"async\"><\/script><\/div>\n            <div class=\"wsbl_twitter\"><a href=\"https:\/\/twitter.com\/share\" class=\"twitter-share-button\" data-url=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/11294\" data-text=\"4 Reasons Why We Need Code Reviews\" data-via=\"GIGASJAPAN_APPS\" data-lang=\"ja\">Tweet<\/a><\/div>\n            <div class=\"wsbl_facebook_like\"><div id=\"fb-root\"><\/div><fb:like href=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/11294\" layout=\"button_count\" action=\"like\" width=\"100\" share=\"false\" show_faces=\"false\" ><\/fb:like><\/div>\n            <div class=\"wsbl_facebook_send\"><div id=\"fb-root\"><\/div><fb:send href=\"https:\/\/www.gigas-jp.com\/appnews\/archives\/11294\" colorscheme=\"light\" ><\/fb:send><\/div>\n    <\/div>\n<br class='wp_social_bookmarking_light_clear' \/>\n","protected":false},"excerpt":{"rendered":"<p>Code reviews are necessary as they offer multiple benefits that help improve your code and your team. These be [&hellip;]<\/p>\n","protected":false},"author":21,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts\/11294"}],"collection":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/users\/21"}],"replies":[{"embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/comments?post=11294"}],"version-history":[{"count":2,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts\/11294\/revisions"}],"predecessor-version":[{"id":11298,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/posts\/11294\/revisions\/11298"}],"wp:attachment":[{"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/media?parent=11294"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/categories?post=11294"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.gigas-jp.com\/appnews\/wp-json\/wp\/v2\/tags?post=11294"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}