{"repo":"creasty/defaults","free":true,"listed":false,"github":"https://github.com/creasty/defaults","clone":"git clone https://github.com/creasty/defaults.git","description":"Initialize structs with default values","language":"Go","stars":860,"topics":["golang","struct","slice","map","nested","initialize"],"license":"MIT","category":"dev-tools","readme_excerpt":"!!! Looking for a new maintainer !!! defaults ======== Initialize structs with default values - Supports almost all kind of types - Scalar types - int/8/16/32/64 , uint/8/16/32/64 , float32/64 - uintptr , bool , string - Complex types - map , slice , struct - Nested types - map[K1]map[K2]Struct , []map[K1]Struct[] - Aliased types - time.Duration - e.g., type Enum string - Pointer types - e.g., SampleStruct , int - Recursively initializes fields in a struct - Dynamically sets default values by defaults.Setter interface - Preserves non-initial values from being reset with a default value Usage -----","default_branch":null,"files":null,"tree":[],"storefront":"/r/creasty","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/creasty/defaults/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}