Open BrunoQuaresma opened 2 years ago
You need window.getComputedStyle
, so perhaps a headless browser instance would make it work
Yes, I'm already using a headless browser, but it is pretty slow, so I was trying to find a better alternative. Thank you.
Crazy idea - just use https://github.com/jsdom/jsdom
I tried, but it didn't work. It gets an error related to canvas even after use node-canvas. 😞
There was a perf-hitting extreme CSS optimisation added in #37 for SVGs.
v2.9.5
.v2.10.1
v2.13.1
- released yesterday - removed the stronger SVG optimization.There's plans to bring it back in #92 as a much quicker post-processing op. Choice of browser is also probably important. But I have no data to suggest anything more than "maybe MS Edge".
Curious to know if it works with node + jsdom
Revisiting here in 2024...
Hi folks,
Just a quick question. Is that possible to run dom-to-image on NodeJS?