I want to use the Jquery start and stop method to appear and disappear my spinner but I can't seem to work with jquery ajax start and stop method when im using the fetch api. how can i walk around this ?
$(document)
.ajaxStart(function() {
$buffer.show();
})
.ajaxStop(function() {
$buffer.hide();
})
;
fetch(url)
.then(data => data.json())
.then(thisObj => writeOnTheScreen(thisObj))
})
;