对Component设置propTypes属性,可以为Component的props属性进行类型检查。 ... oneOf(['News', 'Photos']), // 指定多个类型:你也可以把属性类型 ...
確定! 回上一頁