tsndr / cloudflare-worker-jwt

A lightweight JWT implementation with ZERO dependencies for Cloudflare Workers.
MIT License
649 stars 51 forks source link

consider removing crypto check #34

Closed xhyrom closed 1 year ago

xhyrom commented 1 year ago

We should remove https://github.com/tsndr/cloudflare-worker-jwt/blob/76b7fcef2707225c9214fcba0c4e8d6498039daa/src/index.ts#L1-L2

because when you're building app with Astro for example, it throws error its not supported.

tsndr commented 1 year ago

But it won't work anyway if Crypto Subtle isn't available, so what's the point in removing that check?

xhyrom commented 1 year ago

ah sorry and do you know why when I build the application it throws me that it is not supported? after all Cloudflare Page Functions should support crypto

tsndr commented 1 year ago

Most likely, your bundler is using Node.js.

xhyrom commented 1 year ago

im using Astro with cloudflare adapter