Supported Types
Union Discrimination
Use theType field to determine which variant is active, then access the corresponding field:
Documentation Index
Fetch the complete documentation index at: /docs/llms.txt
Use this file to discover all available pages before exploring further.
state := components.CreateStateStr(string{/* values here */})
state := components.CreateStateMapOfAny(map[string]any{/* values here */})
state := components.CreateStateArrayOfAny([]any{/* values here */})
Type field to determine which variant is active, then access the corresponding field:
switch state.Type {
case components.StateTypeStr:
// state.Str is populated
case components.StateTypeMapOfAny:
// state.MapOfAny is populated
case components.StateTypeArrayOfAny:
// state.ArrayOfAny is populated
}