In your migrations you can do something like:$table->json('field_name'); And in your model you add the field to the $casts property…
Why does this program panic?
var m map[string]float64 m["pi"] = 3.1416
panic: assignment to entry in nil map
You have to initialize the map using the make function (or a map literal) before you can add any elements:
m := make(map[string]float64) m["pi"] = 3.1416