UNPKG

reblendjs

Version:

This is build using react way of handling dom but with web components

44 lines (43 loc) 1.8 kB
import { ReblendTyping } from 'reblend-typing'; import { type BaseComponent } from './BaseComponent'; export interface ReblendReactClass extends BaseComponent { } /** * A static class that extends the functionality of `BaseComponent` * to provide integration with React and Reblend. */ export declare class ReblendReactClass { /** * Returns a React element that wraps the children of the current component for rendering in React. * It ensures that child elements are properly attached to the standard parent container. * * @returns {React.ReactElement} The React element representing the children wrapper for React. */ static getChildrenWrapperForReact<P, S>(elementChildren: Iterable<ReblendTyping.Component<P, S>>): Promise<import("react").ReactElement<{ ref: (node: HTMLElement) => Promise<void>; value?: any; reblendchildrenwrapperforreactcomponent: string; }, string | import("react").JSXElementConstructor<any>> | import("react").ReactElement<{ ref: (node: HTMLElement) => Promise<void>; value?: any; reblendchildrenwrapperforreactcomponent: string; }, string | import("react").JSXElementConstructor<any>>[] | undefined>; html(): any; checkPropsChange(): Promise<void>; /** * Initializes the root for React DOM rendering if it has not been created already. */ initRoot(): Promise<void>; /** * Mounts the React Reblend component by rendering it using the React DOM root and creating a portal * to the standard Reblend React container. * * @protected */ reactReblendMount(): Promise<void>; /** * Cleans up the component by resetting the React DOM root and calling the parent class's cleanup method. * */ cleanUp(): void; }