Downloading javascript image with HtmlUnit
问题 How do I go about downloading the image generated at Leaflet easyPrint button using HtmlUnit? I am trying it like this: public static void main(String[] args) { try{ WebClient webClient = new WebClient(); HtmlPage test = webClient.getPage("http://rowanwins.github.io/leaflet-easyPrint/"); webClient.waitForBackgroundJavaScript(5000); final DomElement button = test.getFirstByXPath("/html/body/button"); final InputStream image = button.click().getWebResponse().getContentAsStream(); System.out