I am new to React and semantic-ui-react. I am creating a table to display a few values, including a boolean, from a mongo database. The column header is defined like this:
<Table.HeaderCell
width={2}
textAlign="center"
sorted={column === "activeFlag" ? direction : null}
onClick={this.handleSort("activeFlag")}
>
Active
</Table.HeaderCell>
And the table rows are rendered like this:
{_.map(data, ({ repoName, repoDesc, activeFlag }, index) => (
<Table.Row className="devRow" key={index} active onClick={e => this.updateRepo(index)}>
<Table.Cell>{repoName}</Table.Cell>
<Table.Cell>{repoDesc}</Table.Cell>
<Table.Cell textAlign="center">{activeFlag}</Table.Cell>
</Table.Row>
)
)}
activeFlag was originally defined as Boolean with default value false, but the value did not appear in the table. When activeFlag was redefined to be a String, then the value appeared in the table. Can boolean values be shown in a table?