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

No file extension #30

Open
habibieamrullah opened this issue Jul 11, 2018 · 2 comments
Open

No file extension #30

habibieamrullah opened this issue Jul 11, 2018 · 2 comments

Comments

@habibieamrullah
Copy link

I thought I can download canvas image with its extension... But it only gives me "download" as a file.
Such thing I can achieve simply by this codes:

var image = document.getElementsByTagName("canvas")[0].toDataURL("image/png").replace("image/png", "image/octet-stream"); window.location.href=image;

@xiatianlong
Copy link

#26

@JonathanTreffler
Copy link

JonathanTreffler commented Aug 2, 2020

I created a fork, that uses ES6 modules and fixes this issue: https://github.com/TessyPowder/canvas2image-2

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