Guest User

Untitled

a guest
Nov 20th, 2017
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.22 KB | None | 0 0
  1. interface IProps {
  2. condition: boolean;
  3. wrap(wrapper: (children: any) => any): any;
  4. children: any;
  5. }
  6.  
  7. export const ConditionalWrap = ({ condition, wrap, children }: IProps) =>
  8. condition ? wrap(children) : children;
Add Comment
Please, Sign In to add comment