I am writing application using AngularJS and Spring. I would like to send request to the server and download response returned from controller as a file. In controller I hav
You can't download a file through an XHR request (which is how Angular makes it's requests). See Why threre is no way to download file using ajax request? You either need to go to the URL via $window.open or do the iframe trick shown here: JavaScript/jQuery to download file via POST with JSON data