Go JSON
Marshaling from and Unmarshaling between JSON and structs in Go, is done using the built-in
Read more ⟶
encoding/json
package and often relies heavily on struct tags…
Go form handling
Instead of passing a
Read more ⟶
name
argument as a URL parameter as we did in our Hello World example, we can improve the user experience using HTML forms. The built-in http.Request
object gives us access to posted form variables, using the PostFormValue()
method.…
Go templates
Go comes with a built-in
Read more ⟶
html/template
package, that supports variables, loops, functions, and more. This allows us to simplify our handlers by delegating the display logic to a template…
Go Chi HTTP router
Using the built-in
Read more ⟶
ServeMux
router is a good way to get started with the net/http
package and the Handler
interface, but for something more serious you might want to look into some of the more advanced routers that are available…
Go HTTP server
Go makes it very easy to create HTTP servers using the standard library
Read more ⟶
net/http
package…
Hello world
Hello world. After years of using Python almost exclusively for everything from web development to data engineering, I’m deep-diving into Go.
Here I will try to document the things I learn as I go.…
Read more ⟶