@antv/s2-react
Version:
use S2 with react
12 lines (11 loc) • 580 B
TypeScript
/// <reference types="react" />
import type { Root } from 'react-dom/client';
export declare const S2_REACT_ROOT_SYMBOL_ID = "__s2_react_root__";
type ContainerType = (Element | DocumentFragment) & {
[S2_REACT_ROOT_SYMBOL_ID]?: Root;
};
export declare const isLegacyReactVersion: () => boolean;
export declare function reactRender(node: React.ReactElement | null, container: ContainerType): void;
export declare function reactUnmount(container: ContainerType): void | Promise<void>;
export declare function forceClearContent(container: ContainerType): void | Root;
export {};