JSON Serialization - The Fine Print
Channel: Maartje Eyskens
Date: 2022-02-05

JSON Serialization - The Fine Print
A journey of JSON serialization
Speaker: Miki Tebeka

We'll look into JSON serialztion, starting from the easy cases and moving toward more advanced ones.

A quiz! Consider the following code:

a := 1
data, _ := json.Marshal(a)
var b interface{}
json.Unmarshal(data, &b)
fmt.Println(a == b)

What will be printed? And why it's "1 1 false"? :)

We all work with JSON, and even though it's a simple format, there are several sharp edges you should should avoid. In this talk, we'll journey from the common well lit areas of JSON serialization and end in some darker corners. I hope you'll enjoy the ride.