I want to disable cache on angular ui grid. How can I do it? It is not mentioned in the documentation or tutorials.
I already have tried this:
$(function () {
console.log("ready!"); //Disable Local Cache
$.ajaxSetup({ cache: false });
});
I want to disable cache on angular ui grid. How can I do it? It is not mentioned in the documentation or tutorials.
I already have tried this:
$(function () {
console.log("ready!"); //Disable Local Cache
$.ajaxSetup({ cache: false });
});
How are providing data to ui-grid? You have to disable caching in the place from where you getting the data. If you are using $http
then you can pass the no-cache
header along with the request.
E.g.
$http.get( 'url' , { headers: { 'Cache-Control' : 'no-cache' } } );
If you are using ajax
then whatever you have commented in the question should work fine.