当我继承/子类化“列”组件时,它会抛出Warning: Failed prop type: Table only accepts children of type Column
这就是我分类的方式Column
import React, {Component, PropTypes} from 'react';
import * as RV from 'react-virtualized';
class Column extends Component {
constructor() {
super();
}
render() {
return (
<RVC.Column {...this.props} type="Column" />
)
}
}
Column.defaultProps = RV.Column.defaultProps;
Column.propTypes = RV.Column.propTypes;
export default Column;
它工作得很好,但我怎样才能避免这个警告呢?