In this example I test html-to-image for client-side image generation. Choose size and pixel ratio and then press Render as PNG to replace the blue div with an image.
If you run the example on a retina display and choose pixel ratio 1 the image will look blurry. Choose a higher pixel ratio and the image will look crisp.