jamesdordoy / laravel-vue-datatable

Vue.js Datatable made for Laravel
https://jamesdordoy.github.io/laravel-vue-datatable
MIT License
151 stars 52 forks source link

Axios request not of type Ajax #124

Closed muarachmann closed 2 years ago

muarachmann commented 3 years ago

Hi there, +1 for this package, how ever, I am trying to implement this feature on the server side if (!$request->ajax()) { abort(404); } but it doesn't seem to work. Looks like the axios get request being sent is not sent as an ajax request. I am trying to limit people from accessing this route by typing in the URL and getting all the data dumped. I could use a middleware but not in all cases I wish to protect some tables.

Please what is the way forward @jamesdordoy doing this with this package