Documentation ¶
Index ¶
Constants ¶
View Source
const (
KeyEscapeRune = '#'
)
Variables ¶
This section is empty.
Functions ¶
func EscapeNonStringKeys ¶
Since Lua allow non-string key within table, we need to escape them by prepending a key escape rune in order to cast as map[string]interface{}. Key escaoe rune '#' indicate the key which is orignal an number key, EscapeNonStringKeys escapes non-string keys of the table.
Types ¶
type KeySortType ¶
type KeySortType int8
const ( KeySortNone KeySortType = iota KeySortHashFnv64 KeySortHashFnv64Reversed KeySortAlphabetical KeySortAlphabeticalReversed )
type Option ¶
type Option func(*options)
An Option is used to define the behavior and rules of a Format.
func IndentWidthStep ¶
IndentWidthStep sets the width of the indentation for each step.
func KeySortPriority ¶
KeySortPriority sets the key sort priority.
func MaxLineLength ¶
MaxLineLength sets the maximum length of a line.
func RootIndentWidth ¶
RootIndentWidth sets the width of the indentation.
Click to show internal directories.
Click to hide internal directories.