Properties
key
key?: string
Unique key for this node
context
context?: (context: NodeContext) => NodeContext
Select props from context and add to context for this node
routes
routes?: { [event: string]: string; }
Routes to listen to
transition
transition?: { fn: (node: HTMLElement, options?: { duration?: number; easing?: (t: number) => number; }) => { duration: number; easing: (t: number) => number; tick: (t: number) => void; }; duration?: number; easing?: (t: number) => number; when: (context: NodeContext) => boolean; }
Apply transition when toggled
spring
spring?: (context: NodeContext) => { [propertyName: string]: { value: number; transform?: (value: number) => number; config?: SpringOptions; }; }
Automatically create springs for props, returned properties are added to context for this node
children
children?: string | TemplateNode | TemplateNode[]
Children of this node, can be falsy children in array