Code reviews, styles and solutions with Software Engineer Yogita

Code reviews, styles and solutions with Software Engineer Yogita

Code reviews are what we are doing now: a run through of someone's code to check for correctness and code quality. They are useful because another pair of eyes can catch bugs and problems easier than the person writing the code.

Code reviews are what we are doing now: a run through of someone's code to check for correctness and code quality. They are useful because another pair of eyes can catch bugs and problems easier than the person writing the code.

Some considerations during code reviews:

Know what you are reviewing. Knowing the code context is important.

Look for bad code smells. Refer to the refactoring book in the description for this.

Factors for good code: readability, correctness, performance.

If you are unsure, do not sign off the review.

Expect tests backing up the author's claims.

Things to keep in mind:

Look for problems. Only suggest solutions.

Don't have long discussions of solutions with other reviewers here. Set a meeting or make a separate report. (Link it to the review later)

Don't try and score points during the review. Don't mention irrelevant or complex solutions to sound cool. (Especially for the fresher engineers)

Don't be nitpicky to sign-off. Fix the code yourself if you have a lot of nitpicky issues. Trust your teammates to improve themselves as they spend time looking at your code.

Offload general issues to the build manager. Styling, formatting, conventions etc… can be parser checks. Test coverage must be compulsory before sending a pull request, etc…

Some tricks for readability:

Use an IDE when doing the review.

Move magic numbers and strings to constants and Enums.

Complex maps should be objects. Nested loops should be broken into functions or graph searches.

Name variables and functions by what they do instead of how or why they do it.

Move common object conversions, validations and other pieces of code to common Utils.

Some tricks for performance:

Use singletons and resource pools where you can.

Constructing and Configuring a client is tricky. There should be dependency injection here.

IO calls are expensive. Use caching, request collapsing and batch queries to reduce load.

Some tricks for resource management:

Make sure resources are being released.

Make sure that race conditions are dealt with.

Logging is critical when handling resources. Log with context.

code visual studio code visual studio

Bootstrap 5 Complete Course with Examples

Bootstrap 5 Tutorial - Bootstrap 5 Crash Course for Beginners

Nest.JS Tutorial for Beginners

Hello Vue 3: A First Look at Vue 3 and the Composition API

Building a simple Applications with Vue 3

Deno Crash Course: Explore Deno and Create a full REST API with Deno

How to Build a Real-time Chat App with Deno and WebSockets

Convert HTML to Markdown Online

HTML entity encoder decoder Online

COMO USAR e trabalhar com Code Review no Visual Studio Code

💲 Live CollabPlay: https://youtu.be/B6LCFSPdsE0 💲 Hospedagem com Desconto Exclusivo: https://tekers.tech/4e587 Não é todo programador que gosta de compartilh...

User Snippets (Code Shortcuts) in Visual Studio Code

#vscode Hello, my friends and fellow developers, this video is all about User Snippets. That means the Snippets (Code Shortcuts) that you can make for yourse...

Python в Visual Studio Code

We are pleased to announce that the July release of the Python extension is now available for Visual Studio Code. You can download the Python extension from the Marketplace, or install it directly from the extension gallery in Visual Studio Code. If you already have the Python extension installed, you can also get the latest update by restarting Visual Studio Code. You can read more about Python support in Visual Studio Code in the documentation .

C++ Development with Visual Studio Code

If you’re looking for a fast and lightweight open-source code editor, Visual Studio Code has you covered. Come for a deep dive into the features of Visual Studio Code which provide a rich, productive environment for C++ development.

The History of Visual Studio Code

We speak to the creator of Visual Studio Code about the early challenges to now becoming the most popular development environment in the world.