Documentation ¶
Overview ¶
Package flatten is a simple library to flatten JSON into dot notation. Forked from https://github.com/17twenty/flatter
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Map ¶
Map is our datatype we use to extend the base types and allow easier flattening
func Flatten ¶
Flatten takes a structure and turns into a flat map[string]string.
Within the "thing" parameter, only primitive values are allowed (slices, maps, primitives, and any combination of those together)
func (Map) Merge ¶
Merge merges the contents of the other Map into this one.
This merge is smarter than a simple map iteration because it will fully replace arrays and other complex structures that are present in this map with the other map's. For example, if this map has a 3 element "foo" list, and m2 has a 2 element "foo" list, then the result will be that m has a 2 element "foo" list.