Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ReferenceError: Can't find variable: SharedArrayBuffer #37

Closed
matiasmenares opened this issue Apr 3, 2021 · 4 comments
Closed

ReferenceError: Can't find variable: SharedArrayBuffer #37

matiasmenares opened this issue Apr 3, 2021 · 4 comments

Comments

@matiasmenares
Copy link

image

I have the 6.1.0 version but safari throw the error, in chrome work normally

if i comment the line lib/index.js line 348 work correctly

image

image

@alcheco
Copy link

alcheco commented Apr 3, 2021

Very interesting problem I have the same issue

@victorlin
Copy link

I have a similar issue (Safari only, works fine on Chrome):

ReferenceError: Can't find variable: BigInt
node_modules/webidl-conversions/lib/index.js:158

function createLongLongConversion(bitLength, { unsigned }) {
const upperBound = Number.MAX_SAFE_INTEGER;
const lowerBound = unsigned ? 0 : Number.MIN_SAFE_INTEGER;
const asBigIntN = unsigned ? BigInt.asUintN : BigInt.asIntN;

@victorlin
Copy link

Seems like this is why: magiclabs/magic-js#131 (comment)

... runs on top of JavaScriptCore which doesn't have support yet for BigInt nor SharedArrayBuffer. In theory and assuming this is the root cause, the library might work just fine on Chrome but have similar issue on Safari which also runs on top of JavaScriptCore.

Until JavaScriptCore adds support for these, I'll have to avoid using jsdom in my project unless there is a workaround.

@matiasmenares
Copy link
Author

@victorlin I had to do the same, i removed from project

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants