Skip to content

LayerRenderable

Defined in: packages/renderer/src/SortGroupComponent.ts:21

Contract a single-display-object visual component satisfies: a layer name plus the Pixi object it renders. All five built-in visual components (SpriteComponent, GraphicsComponent, AnimatedSpriteComponent, TextComponent, SplitTextComponent) expose it through their renderObject getter, and SortGroupComponent uses it to gather a subtree’s visuals without importing the concrete classes (which would create an import cycle).

It’s also the extension point for custom visual components: implement renderObject + layerName, and route through resolveRenderParent in onAdd, and the component takes part in sort groups exactly like the built-ins.

readonly layerName: string

Defined in: packages/renderer/src/SortGroupComponent.ts:23

Name of the layer this component renders into.


readonly renderObject: Container

Defined in: packages/renderer/src/SortGroupComponent.ts:25

The underlying Pixi display object.