I have been attempting to download JSON data into a JSON file using the code snippet below, but all it does is present me with a blank page in Internet Explorer. I am in search of a solution to download the JSON file without triggering any events on the user interface.
var dataUri = "data:text/json;charset=utf-8," + encodeURIComponent(JSON.stringify(JSONData));
var downloadAnchorNode = document.createElement('a');
downloadAnchorNode.setAttribute("href", dataUri);
downloadAnchorNode.setAttribute("download", "CarData.json");
downloadAnchorNode.click();