html2image
html2image copied to clipboard
Add the --force-device-scale-factor parameter
On Linux servers, there may sometimes be a situation where the DPI (dots per inch) is too low. I added this parameter while ensuring that it wouldn't affect the previous version of the code as much as possible. This parameter can be adjusted accordingly.
hti = Html2Image(
browser=browser,
output_path=OUTPUT_PATH,
disable_logging=True,
force_device_scale_factor=2,
)
Perhaps I should shorten the name of this parameter.