Documentation ¶
Index ¶
- func GetVar(ctx context.Context, key string) lua.LValue
- func Load(path string, v any) error
- func LoadContext(ctx context.Context, path string, v any) error
- func NewContextMetatable() *lua.LTable
- func NewContextVM(ctx context.Context) *lua.LState
- func Render(lyml []byte) (res []byte, err error)
- func RenderContext(ctx context.Context, lyml []byte) (res []byte, err error)
- func SetVar(key string, value any) error
- func SetVars(vars map[string]any) error
- func Transform(lyml []byte) (res *yaml.Node, err error)
- func TransformContext(ctx context.Context, lyml []byte) (res *yaml.Node, err error)
- func Unmarshal(data []byte, v any) error
- func UnmarshalContext(ctx context.Context, data []byte, v any) error
- func WithVar(ctx context.Context, key string, value any) context.Context
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadContext ¶
Load is unmarshal with file path.
func NewContextMetatable ¶
func NewContextVM ¶
Creates a new VM with a context.
func RenderContext ¶
Render takes a lyml document and returns a valid yml document with all special nodes evaluated.
func TransformContext ¶
Transform takes a lyml document and returns the parsed yaml.Node.
func UnmarshalContext ¶
Unmarshal transforms a lyml document into a yml one and then unmarshals it into the given value.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.