Skip to content

ops-school/coding-style-guide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 

Repository files navigation

Coding Style Guide

** 🎱 When coding we always seek to**

  1. Implement what is required, not wished
  2. Be concise, clear, and readable
  3. Get feedback fast and as much as possible
  4. Conform to the standard coding practices of the public community
  5. Exploit the power of the programming language we write with

Coding Practices

KISS

Keep it simple stupid! Nobody likes complex code. it is just not maintainable in the long term.

Readability

At all costs! people read more code than they write. make sure your code is always readable to someone else. Ask for a review to be sure.

DRY

Don’t repeat yourself (unless youreally really really really have to). Every duplicated will cost you time & money and can potentially cause you bugs.

Naming

Use meaningful names for EVERY line of code you write! Every variable, function or class. Everything!

Single Responsibility!

A piece of readable code (be it function, class or block) should do one and one thing only (As a rule of thumb, when naming a block of code, if you find you use the terms “and” or “or” it means it does more than one thing)

No Comments Please!

Unless not having a comment will make the code completely unreadable or you’re documenting an API. Comments clutter your code and are subject to being irrelevant in the short and lon term as code changes rapidly

Don't Re Invent The Wheel

Use the power and ecosystem of your programming language of choice in your coding. Actively search and use Built in functions, tools, and libraries to support your implementations

Be "Stylish"

Learn about what is the "good way" of writing code in the programming language you choose to write. In the web there is a plethora of "style guides" that advocate the correct "style" to write in each programming language.

Use automatic programming language tools such as Linters or other static code analysis tools in order to maintain Style.

Run it!

Run your code often. Be it small or big. Use interactive shell or other tools to run and experiment while coding. By actively doing this you will get better familiarity with the programming languagewhich will eventually make you a better programmer

Get Feedback!

Code will never be complete without proper feedback from another person. ask for it for ANY code you write

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published