import React from 'react' import PropTypes from 'prop-types' import Text from './text' import TableColumnHeader from './table_column_header' import TableRow from './table_row' class Table extends React.PureComponent { render() { const { id, columns, rows, } = this.props return ( { Array.isArray(columns) && { columns.map((column, i) => ( )) } } { Array.isArray(rows) && rows.map((row, i) => ( )) }
) } } Table.propTypes = { id: PropTypes.string, columns: PropTypes.array, rows: PropTypes.array, } export default Table