How to set cache false for getJSON in jQuery?

Your code just needs a trigger for it to be enabled.

This will allow you to disable cache in all future ajax

$(document).ready(function() {
  $.ajaxSetup({ cache: false });
});

Hope it helps 🙂

Leave a Comment