Skip to content

@serenity-is/corelib / ComponentClass

Interface: ComponentClass<P, T>

Defined in: ../domwise/dist/index.d.ts:2345

A class-based JSX component. Extend Component or implement this interface and override render to return a JSXElement.

Type Parameters

P

P = { }

The type of the component's props.

T

T extends Node = JSXElement

The type of the DOM node the component renders.

Constructors

Constructor

new ComponentClass(props): ComponentInstance<P, T>

Defined in: ../domwise/dist/index.d.ts:2350

Constructs the component with the given props.

Parameters

props

P

Props including optional children.

Returns

ComponentInstance<P, T>

Properties

defaultProps?

optional defaultProps: Partial<P>

Defined in: ../domwise/dist/index.d.ts:2352

Optional default prop values merged in by the JSX factory before construction.


displayName?

optional displayName: string

Defined in: ../domwise/dist/index.d.ts:2354

Optional display name used in devtools / error messages.