Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR TYPESCRIPT

ts react props type

type Props = {
  size: string;
}

const Component = ({ size = 'medium' }: Props) => (
  <div className={cn('spinner', size)} />
);
 
PREVIOUS NEXT
Tagged: #ts #react #props #type
ADD COMMENT
Topic
Name
9+4 =