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

Cloudflare Workers - toBuffer with jpeg fails due to reliance on jpeg-js #619

Open
matthewhardern opened this issue Apr 6, 2023 · 2 comments

Comments

@matthewhardern
Copy link

toBuffer as above fails due to jpeg-js reliance on Buffer.from(), although cloudflare workers can use Buffer it needs to be added with 'node:buffer' package. The png works perfectly, would be nice to work on updating the fast-jpeg and using that to remove this reliance? Awesome library BTW, its been the easiest one to setup on cloudflare workers. Happy to create a PR for docs on usage if anyone would like.

@stropitek
Copy link
Contributor

Have you tried opening an issue in the jpeg-js repo? fast-jpeg doesn't read / write jpeg, only metadata so we can't rely on that.

@targos
Copy link
Member

targos commented Apr 8, 2023

Yeah, I'm not sure there's anything we can do if the problem is in jpeg-js

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