AllenFang / AllenFang/react-bootstrap-table

got warning message when editable property is function which return false

Open
#1,909 2 comments 1 reaction 0 assignees View on GitHub
Dominant language
JavaScript
Stars
2.2k
Forks
761
PR merge metrics
No merged PRs in 30d

Description

When:
- editable property of TableHeaderColumn is a function
- the function returns false value

Then:
there is a warning message in console.

```
warning.js?6327:33 Warning: Received `false` for a non-boolean attribute `type`.

If you want to write it to the DOM, pass a string instead: type="false" or type={value.toString()}.

If you used to conditionally omit it with type={condition && value}, pass type={condition ? value : undefined} instead.
in input (created by TableEditColumn)
in td (created by TableEditColumn)
in TableEditColumn (created by TableBody)
in tr (created by TableRow)
in TableRow (created by TableBody)
in tbody (created by TableBody)
in table (created by TableBody)
in div (created by TableBody)
in TableBody (created by BootstrapTable)
in div (created by BootstrapTable)
in div (created by BootstrapTable)
in BootstrapTable (created by DocumentList)
in div (created by DocumentList)
```

this line sets ``

https://github.com/AllenFang/react-bootstrap-table/blob/ec9f036698362a5e4296920049ad3283ee66356b/src/Editor.js#L14

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.