UNPKG

conditional-wrapper

Version:

A React component with which you can conditionally wrap child components

8 lines (7 loc) 306 B
/// <reference types="react" /> export declare type Props = { condition: boolean; wrapper: (children: JSX.Element | JSX.Element[]) => JSX.Element; children: JSX.Element | JSX.Element[]; }; export declare function ConditionalWrapper({ condition, wrapper, children }: Props): JSX.Element;