2NVC
24_0001 Nguyễn Văn Cảnh

Menu Icon - Copy this React, Tailwind Component to your project

Upgrade using typescript and this component has 2 props is "component" and "renderRoot", prop "component" is ElementType (default html, svg tag and user custom component) and infer that MenuIcon has props includes defined by itself and props of prop "component", if "component" is "button" add more type=button for result, if prop "renderRoot" is set, it is a function give props from inside MenuIcon includes children and return ReactElement, priority higher prop "component"

Prompt

About

MenuIcon - A customizable square icon component with props for radius, size, variant, and color, professionally built with React and Tailwind. View and copy code!

Share

Last updated 1 month ago