mirror of
https://github.com/thatmattlove/hyperglass.git
synced 2026-04-18 13:58:27 +00:00
6 lines
182 B
TypeScript
6 lines
182 B
TypeScript
import type { TIf } from './types';
|
|
|
|
export const If = (props: TIf) => {
|
|
const { c, render, children, ...rest } = props;
|
|
return c ? (render ? render(rest) : children) : null;
|
|
};
|