If I use "defaultChecked", sorting table columns does not change the position of the checkbox.  

If use "checked", I can change position but checkbox doesn't work correctly.  

How can I fix it?   

Here is the code: [<https://jsfiddle.net/sakanyan/e2a56mbk/29/>](https://jsfiddle.net/sakanyan/e2a56mbk/29/ "example")   

```
enter code here
<input  type="checkbox" checked={item.hasItem} /*OR 
defaultChecked={item.hasItem} */ />

```