Establecer DataTable con JQuery Success Valor de retorno
success: function(respone){
table.destroy(); //destruy allow to reinitialize
const res = JSON.parse(respone); // parse if got encode in server
const response_object = res.data;
// data:{['record','record'],['record','record']...}
console.log(response_object);
$('#table_id').DataTable( {
data: response_object,
// datatablesetting....
} );
}
Clean Cod