import type { Entity } from "./Entity"; export declare class Component { static has(entity: Entity): boolean; static clear(entity: Entity): boolean; static argMap: string[]; readonly entity: E; readonly derived: boolean; constructor(entity: E, ...rest: InitializationParameters); protected initialize?(...rest: InitializationParameters): void; dispose(): void; /** * Disposes `this` and adds a new component of the same type to the entity. * Skips informing the app the original component was removed and instead * relies on the new component informing the app of the change. */ replace(...args: InitializationParameters): Component; toJSON(): { type: string; [key: string]: unknown; }; static fromJSON(...args: ConstructorParameters): Component; } export interface ComponentConstructor { new (...args: any[]): T; fromJSON: typeof Component["fromJSON"]; argMap: string[]; } export declare const isComponentConstructor: (value: unknown) => value is ComponentConstructor>;