import React from "react"标签:React,const,48,disabled,className,基础架构,react18,MenuItem,children From: https://blog.51cto.com/u_15460007/6052013
import classNames from 'classnames'
export interface MenuItemProps {
index?: string;
disabled?: boolean;
className?: string;
style?: React.CSSProperties;
children?:any
}
const MenuItem: React.FC<MenuItemProps> = (props) => {
const { index, disabled, className, style, children } = props
const classes = classNames('menu-item', className, {
'is-disabled': disabled
})
return (
<li className={classes} style={style}>
{children}
</li>
)
}
MenuItem.displayName = 'MenuItem'
export default MenuItem