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

Export a graph to png or base64 #504

Closed
bastientardits opened this issue Jun 9, 2023 · 2 comments
Closed

Export a graph to png or base64 #504

bastientardits opened this issue Jun 9, 2023 · 2 comments

Comments

@bastientardits
Copy link

Hello and thank you for this much useful package.
I'm currently building an angularservice for my working place's solution. This package was already installed before my arrival, which could explain some of my confusion.
I would like to know if a functionnality allowing the user to save a graph as a png or convert it to base64 exists in this package? I tried some things with html2canvas package for example, but I can't make anything work.
I'm creating documentation in the form of an html file that I export and download. I would like to document a graph ,and so, to add a visual representation of that graph in the html file, either as an image or a base64 string for .
If you have any ideas or recommandations, I would be very grateful
Thank you and have a good day

@arbertrary
Copy link

arbertrary commented Jul 3, 2023

Hi,

maybe you've found this already and maybe it doesn't fit your needs but there's this project which has not been maintained anymore for the last 3 years but it still does the basic work:

https://github.com/exupero/saveSvgAsPng

Typings: https://github.com/ksholla20/save-svg-as-png-typings

@bastientardits
Copy link
Author

Hi @arbertrary thanks for your answer and sorry for the late response. I actually figured out the svg does fit in the html file perfectly and there was no need to convert it.
Have a good day

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

2 participants