函数: createElement()
使用 snapshot 运行时创建 ReactLynx 元素。
调用签名
createElement<
Typeextends keyofIntrinsicElements>(type:Type,props?:IntrinsicElements[Type] |null, ...children:ReactNode[]):ReactElement<IntrinsicElements[Type],Type>
创建一个 Lynx 内置元素。
类型参数
参数
返回
ReactElement<IntrinsicElements[Type], Type>
调用签名
createElement<
Propsextendsobject>(type:string|ComponentType<Props>,props?:Attributes&Props|null, ...children:ReactNode[]):ReactElement<Props>
创建一个组件元素。
类型参数
参数
返回
ReactElement<Props>