Beagle v1.7 is no longer actively maintained. The documented version you are viewing may contain deprecated functionality. For up-to-date documentation, see the latest version .
ContextComponent
is an interface that it is necessary to be implemented in components that use Context, because it contains the context attribute.
See below an example with customized components with context:
@RegisterWidget
data class CustomComponent(
val otherAttribute: String
override val context: ContextData? = null
): WidgetView(), ContextComponent
@RegisterWidget
data class CustomComponent(
val otherAttribute: String
override val context: ContextData? = null
): Widget(), ContextComponent
public struct CustomComponent: Component, HasContext {
public var context: Context?
public var otherAttribute: String
}
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.