npm-trends icon indicating copy to clipboard operation
npm-trends copied to clipboard

Cors error in production for getting package info

Open oonsamyi opened this issue 2 years ago • 3 comments

Hello!

First of all, very good service! I often use it.

I go to https://www.npmtrends.com, enter some package name e.g. react and package info doesn't load. I see cors error in console. image image

oonsamyi avatar Oct 13 '21 16:10 oonsamyi

Same here

fehergeri13 avatar Oct 13 '21 17:10 fehergeri13

Easy to reproduce the error from the CLI:

curl 'https://proxy.npmtrends.com/?url=https://api.npms.io/v2/package/fetch'

The error itself might not be CORS related; the type shown in the object is the type of request made. It's just an internal server error (500).

bendman avatar Oct 21 '21 09:10 bendman

I think this is related to github rate limit: https://github.com/johnmpotter/npm-trends/issues/116

fehergeri13 avatar Oct 21 '21 09:10 fehergeri13