Loading json data from local endpoint in django application
Loading json data from local endpoint in django application
peter-werk
Posts: 8Questions: 4Answers: 0
I have a problem loading my data from the local endpoint in Django application. Everything seems to be fine in the console data is showing properly no errors, just not loading my data into the DataTable
js component
var dt = $('#data').DataTable({
"pageLength": 25,
responsive:true,
ajax: "/data/json/",
columns: [{
Answers
Hard to tell. Please post a test case.
Have your checked your HTML? Is it really matching your datatable?
Looks like you need to use
ajax.dataSrc
to tell Datatables where to find the data. Use an empty string as shown in one of the examples. See this doc for more details.Kevin