How to receive the height of DOM element when printing with wkhtmltopdf library?
问题 When I try to get offsetHeight or of any DOM element with Javascript when printing with wkhtmltopdf library, the height is never determined and is always equal to 0. When I execute the same JS code in any browser it works correctly and results in a specific height of element. I googled for a long time and I found out that it might be related with wkhtmltopdf in which the width and height of document and window are equal to 0. I tried to override the size of the body tag with CSS and override