DIY Life Hacks , Fun Stuff, and Programming Blog

Go sql examples

Go sql examples using sqlx Assume you have two models a type Business and a type Widget in a one to many relationship. I want to demonstrate two ways that you can load the...

Golang YAML to map

How to convert a YAML file to a map[string]string in Go Use go-yamlconfigfile project to convert simple yaml config files to maps in Go. When you want to store secrets for your project, you...

Go Closures as Struct Members

How to store closures at runtime inside struct members in the Go programming language.   I will also show you how you can change the closure stored as a member inside of your struct...