I am trying to consume the Flickr API using angular, however whenever I try and make a request I get this error. I have looked online but can't seem to get a decent answer
XMLHttpRequest cannot load https://api.flickr.com/services/feeds/photos_public.gne?tags=potato&tagmode=all&format=json. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:8000' is therefore not allowed access.
Here is my code for the request - I am trying to do this 100% with angular and not have to run a server
FlickrController.$inject = ['$http']
function FlickrController($http){
var self = this
this.newPhoto = {}
// this.photos = Photo.query();
this.getPhoto = function(){
console.log('gettinghere')
$http
.get('https://api.flickr.com/services/feeds/photos_public.gne?tags=potato&tagmode=all&format=json')
.then(function(response){
var photoData = response.data
console.log(photoData)
self.addPhoto(photoData)
})
}