Readonly
featureFeature class this context is created for.
Readonly
onAn OnEvent
sender of component construction events.
The registered receiver will be notified right before component is constructed.
Readonly
onAn OnEvent
sender of component definition events.
The registered receiver will be notified when new component class is defined, but before its custom element class constructed.
Readonly
supplyFeature supply.
Cut off once feature unloaded.
Readonly
whenAn OnEvent
sender of feature readiness event.
The registered receiver will be notified once bootstrap is complete and the feature is loaded.
If the above conditions satisfied already, the receiver will be notified immediately.
Defines a component.
Creates a custom element according to component definition, and registers it with custom elements registry.
Note that custom element definition will happen only when all features configuration complete.
Custom element class constructor registered as custom element.
TypeError If componentType
does not contain a component definition.
A type of component.
Component class constructor.
Obtains value of the given context entry.
Either context entry value, or a fallback one.
Requested context value type.
Context entry to obtain the value of.
Optional
request: WithoutFallback<TValue>Context value request with fallback specified.
Obtains value of the given context entry, or returns a non-nullable fallback.
Either context entry value, or a fallback one.
Requested context value type.
Context entry to obtain the value of.
Context value request with fallback specified.
Obtains value of the given context entry, or returns a nullable fallback.
Either context entry value, or a fallback one.
CxReferenceError - If the target entry
has no value and fallback one is not provided.
Requested context value type.
Context entry to obtain the value of.
Optional
request: CxRequest<TValue>Context value request.
Allows to loads the given feature
.
Loaded feature reference.
The feature to load.
Optional
user: SupplyPeerThe user of the feature. The feature reference will be dismissed once the user's supply is cut off.
Provides asset for entry available in each component context.
Asset supply. Revokes provided asset once cut off.
Context value type.
Context value asset type.
Context entry asset.
Provides asset for entry available in each component definition context.
Asset supply. Revokes provided asset once cut off.
Context value type.
Context value asset type.
Context entry asset.
Provides asset for bootstrap context entry
Note that this happens when bootstrap context already exists. To provide a value before bootstrap context created a provide method can be used.
Asset supply. Revokes provided asset once cut off.
Context value type.
Context value asset type.
Context entry asset.
Sets up the definition of component of the given type.
Whenever the definition of component of the given type or any of its subtype starts, the returned OnEvent
sender
sends a DefinitionSetup instance, that can be used to set up that definition.
An OnEvent
sender of component definition setup instances.
Target component type.
Allows to wait for component definition.
This corresponds to window.customElements.whenDefined()
method.
An OnEvent
sender of definition context sent when the given componentType
is registered.
A type of component.
Component class constructor.
Generated using TypeDoc
Feature initialization context.