domenic / svg2png

Converts SVGs to PNGs, using PhantomJS
Other
585 stars 134 forks source link

Question : Can I pass SVG as markup #89

Closed gs-akhan closed 7 years ago

gs-akhan commented 7 years ago

HI, I was looking for anyway I can pass data as markup instead of SVG file.

Thanks

domenic commented 7 years ago

Yes; svg2png accepts a Buffer parameter. If you need help figuring out how to create a buffer with a given string, I'd suggest consulting the Node.js docs, or StackOverflow.

gs-akhan commented 7 years ago

Got it. Thank you very much..