UNPKG

@intility/bifrost-react

Version:

React library for Intility's design system, Bifrost.

16 lines (15 loc) 558 B
/** * Wraps a client component as a server component, so that submodules can be assigned to it * * @private only meant for internal use * * @param ClientComponent the component to wrap (function reference) * @param displayName name of the ClientComponent (string) * @returns A Server Component with the same type signature as the input component * * @example * Object.assign(wrapClientComponent(Dropdown, "Dropdown"), { * Item: DropdownItem, * }); */ export declare function wrapClientComponent<T>(ClientComponent: T, displayName: string): T;