7 ms·
Good as html2canvas is, these days you may get more milage creating an SVG, putting the HTML content in it as a ForeignObject, and then using the browser's abil
by onion2k 6y ago
Good as html2canvas is, these days you may get more milage creating an SVG, putting the HTML content in it as a ForeignObject, and then using the browser's ability to copy an image to a canvas with the SVG as the source. I use that technique in a very complex diagramming app I work on and it never seems to fail regardless of the HTML content. Getting fonts and external styles to work is fun but that wouldn't apply here.
- xamde 6y agoOff-topic, but please tell us more about the diagramming app.