create

open fun create(context: Context, component: Component): LithoView

Create a new LithoView instance and initialize it with the given Component root.

Return

LithoView able to render a Component hierarchy.

Parameters

context

Android Context.

component

The root component to draw.


open fun create(context: Context, component: Component, lifecycleProvider: LithoVisibilityEventsController): LithoView


open fun create(context: ComponentContext, component: Component): LithoView

Create a new LithoView instance and initialize it with the given Component root.

Return

LithoView able to render a Component hierarchy.

Parameters

component

The root component to draw.


open fun create(context: ComponentContext, component: Component, lifecycleProvider: LithoVisibilityEventsController): LithoView

Creates a new LithoView and sets a new ComponentTree on it. The ComponentTree is subscribed to the given LithoVisibilityEventsController instance.


open fun create(context: Context, componentTree: ComponentTree): LithoView
open fun create(context: ComponentContext, componentTree: ComponentTree): LithoView

Create a new LithoView instance and initialize it with a custom ComponentTree.