laurengarcia / url-metadata

NPM module: Request a url and scrape the metadata from its HTML using Node.js or the browser.
https://www.npmjs.com/package/url-metadata
MIT License
166 stars 44 forks source link

Getting Cors Error #17

Closed maks112v closed 4 years ago

maks112v commented 5 years ago

Access to fetch at 'https://dribbble.com/' from origin 'http://localhost:3000' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.

mamta-vkl commented 5 years ago

I'm also getting the CORS error, can anyone please suggest a solution for that?

sukitz commented 5 years ago

I'm also getting the CORS error, can anyone please suggest a solution for that?

I worked 'https://cors-anywhere.herokuapp.com/+url'

example https://cors-anywhere.herokuapp.com/https://www.foo.com

varun-capcons commented 4 years ago

I am using this in lambda function and use it as api using api gateway and giving me error has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

and ERROR Error: Uncaught (in promise): HttpErrorResponse: {"headers":{"normalizedNames":{},"lazyUpdate":null,"headers":{}},"status":0,"statusText":"Unknown Error",

How to resolve it..

laurengarcia commented 4 years ago

https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS