Viewscreen

[中文]

Overview

viewScreen is a mountable top-level screen, mountable at runtime via mount_screen(...) or screenFlow at the mount path /<id>.

Fields

Key

Type

Default

Required

Description

type

string

none

Yes

Fixed to "viewScreen"

id

string

none

Yes

Screen id; the mount path is /<id>

mountMode

eager / dynamic

eager

No

dynamic means the subtree is created on first mount

commonProps

object

baseline

No

Common state, see Commonprops

layout

object

baseline

No

Direct child layout, see Layout

placement

object

baseline

No

Placement of the current node, see Placement

style

object

theme merge result

No

Visual style, see Style

stateStyles

object

{}

No

State style overrides, see State Styles

styleRefs

string[]

[]

No

Named style references, see View

events

array

[]

No

Event declarations, see Events

animations

array

[]

No

Declarative animations, see Animations

bindings

object

{}

No

Store bindings, see Bindings

children

array

[]

No

Child nodes or templateRef

{
    "type": "viewScreen",
    "id": "home",
    "children": [
        {"type": "label", "id": "title", "labelProps": {"text": "Home"}}
    ]
}