Describe the bug
The ClearRows() method of a table sets the data to nil, but in the New() function to create a new table model, it is set to NewStringData(). Therefore if you want to clear a table of all its rows, you will not be able to add rows later. Rows will only be appended if the type of the internal data is StringData, which is not true after calling ClearRows().
Describe the bug The
ClearRows()
method of a table sets thedata
tonil
, but in theNew()
function to create a new table model, it is set toNewStringData()
. Therefore if you want to clear a table of all its rows, you will not be able to add rows later. Rows will only be appended if the type of the internaldata
isStringData
, which is not true after callingClearRows()
.Source Code table.go