Skip to main content

ErasedSchemaSubclassable TypeAlias

The type of a subclassable erased schema.

This API is provided as an alpha preview and may change without notice.

To use, import via fluid-framework/alpha.

For more information about our API support guarantees, see here.

Signature

export type ErasedSchemaSubclassable<TExtra, Identifier extends string> = TreeNodeSchemaClass<Identifier, NodeKind, ErasedNode<TExtra, Identifier>, never, false>;

Type Parameters

ParameterConstraintDescription
TExtra
Identifierstring

Remarks

Provides an isolatedDeclarations compatible way to explicitly type the return value from eraseSchemaDetailsSubclassable().

Example

export const SquareSubclassable: SquareSchema &
ErasedSchemaSubclassable<SquareNode, "com.example.Demo"> = eraseSchemaDetailsSubclassable<
Square,
SquareSchema
>()(SquareInternal);

class SquareSubclass extends SquareSubclassable {}