paralleldrive/cuid2

Use of Big Integers limits browser support

toBeOfUse opened this issue · 1 comments

cuid2 recently started using the newer JavaScript BigInt type. BigInts require ES2020 and are supported only by 95% of browsers. Polyfills for BigInts are slow and unpopular; ESBuild won't support one and Babel "doesn't support transforming BigInts.". Is support for the 1 in 20 people who use a non-BigInt-compatible browser on your radar?

yeah, use of bigint prevent us using it in browser environments. specifically this function:

function bufToBigInt(buf) {

and according to the comment in here, its tricky:
evanw/esbuild#732

😞