lza07a
Last Updated: September 09, 2019
·
1.096K
· hemanth

CORS with AngularJS

var myApp = angular.module('myApp', []);

myApp.config(['$httpProvider', function($httpProvider) {
        $httpProvider.defaults.useXDomain = true;
        delete $httpProvider.defaults.headers.common['X-Requested-With'];
    }
]);