JSFiddle - React, Tailwind, and code Playground

HTML

<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.21/css/jquery.dataTables.min.css" />
<script type="text/javascript" src="https://code.jquery.com/jquery-3.5.1.js"></script>
<script type="text/javascript" src="https://cdn.datatables.net/1.10.21/js/jquery.dataTables.min.js"></script>

<script type="text/javascript">
    $(document).ready(function () {
        var table = $('#example').DataTable({
        });
$('#example tbody').on('click', 'input', function () {
console.log('check')
  table.draw();
})

});

    //https://datatables.net/manual/plug-ins/search
    $.fn.dataTable.ext.search.push(
        function (settings, data, dataIndex) {
          var api = new $.fn.dataTable.Api( settings );
          var tr = api.row( dataIndex ).node();
          alert( $(tr).find('input').prop('checked') )
          return true;
        }
    );
    
    

</script>

<table id="example" class="display" style="width:100%">
    <thead>
        <tr>
            <th>id</th>
            <th>checkbox</th>
        </tr>
    </thead>
    <tbody>
        <tr>
            <td>1</td>
            <td><input type="checkbox" value="check0"></td>
        </tr>
        <tr>
            <td>2</td>
            <td><input type="checkbox" value="check1"></td>
        </tr>
    </tbody>
</table>