Skip to content

tokoinofficial/coding-covension

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 

Repository files navigation

coding-standard

This based on the consensus between devs.

Requirements:

Common:

  • Use gitflow to manage code.
    • Basically, there are 2 branches: master and develop. master is used for production and develop for staging environment.
    • All your features must be created from the develop branch.
    • Once it's done, please create a pull request from your feature to the develop branch. The CI will run automatically.
    • Assign a reviewer for your pull request.
  • The code must be tested.
  • Remove redundant code.
  • Remove duplication code.
  • Remove rem code.
  • Meaning function or method name.

Jira:

  • Put your due date for the task you do. Thanks to @Binh to raise this issue.
  • Move the task from TO DO to IN PROGRESS.
  • Create a pull request with the name is your task number (Ex: TW-5). Show your evidence like screenshots, gif, ... Thanks to @Ivan to make it more clearly.
  • Follow the task based on our roadmap. If you see it's not important for now, please move it to our BACK LOG.

Golang:

No.1

BAD

var (
    mongoInstance *mongo.Database
)

type MongoDB struct {
}

func GetInstance() *mongo.Database {
    return &mongoInstance
}

GOOD

type MongoDB struct {
    mongoInstance *mongo.Database
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published