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: SharedArrayBuffer is not defined #126

Closed
tsafs opened this issue Dec 10, 2020 · 4 comments
Closed

ReferenceError: SharedArrayBuffer is not defined #126

tsafs opened this issue Dec 10, 2020 · 4 comments

Comments

@tsafs
Copy link

tsafs commented Dec 10, 2020

Hi

Thanks for the module, it's been giving me a good idea of what I can do with the canvas. I will not be using this module anymore, but just found an error that you might be interested in.

It's occurring on the latest React version with the latest react-sketch version and only on the latest versions (probably also earlier versions) of Firefox, Firefox Mobile, Opera Mobile, others I haven't tested.

ReferenceError: SharedArrayBuffer is not defined
./node_modules/webidl-conversions/lib/index.js
C:/Users/Sebastian/Projects/Cards/client_new/node_modules/webidl-conversions/lib/index.js:347

  344 | 
  345 | const abByteLengthGetter =
  346 |     Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "byteLength").get;
> 347 | const sabByteLengthGetter =
  348 |     Object.getOwnPropertyDescriptor(SharedArrayBuffer.prototype, "byteLength").get;
  349 | 
  350 | function isNonSharedArrayBuffer(V) {

It is because those browsers do not support SharedArrayBuffer.

I haven't dug deeper into the issue, because I'm dropping your module from my work, but here you go.

Happy hacking 👍

@amitnjha
Copy link

amitnjha commented Jan 4, 2021

I am facing same error. It seems the component is not compatible with React 17, It works fine with React 16.

@scand1sk
Copy link

i ran the same error. I am still with React 16, for me it was triggered when I upgraded react-scripts to v4.x.x.

@scand1sk
Copy link

Upgrading react-sketch to 0.5.7 (using the npm module "react-sketch2") seems to have solved my issue.

@LaurentGENTY
Copy link

Upgrading react-sketch to 0.5.7 (using the npm module "react-sketch2") seems to have solved my issue.

Solved issue too

@tsafs tsafs closed this as completed May 23, 2023
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

4 participants