Skip to content

Yusufaffandi2000/solid-in-golang

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SOLID Principle in Golang

SOLID is an object-oriented design (OOD) principles by Robert C. Martin (Uncle Bob), have 5 principles :

  1. Single Responsibility Principle
  2. Open / Closed Principle
  3. Liskov Substitution Principle
  4. Interface Segregation Principle
  5. Dependency Inversion Principle

Why

To make project easier to maintain and extend as project grows, with avoiding bad code that have some indicators :

  1. Rigidity (Difficult to change, even small pieces)
  • Dont aware of improvement of some feature
  1. Fragility (Easily crashed when code being changed)
  • Dont aware of unexpected condition
  1. Immobility (Hard to refactor, not reusable)
  • Write a whole busines rules in one function
  1. Viscosity (Like swim in syrup)
  • Bad written, pattern, or documentation.

Presentation

Stay in touch

Reference

About

Learn more about SOLID Principle in Golang

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%