I'm using wkhtmltopdf for print my html code, this code has leaflet maps, my problem is pdf file doesnt't print the map properly, it seems it doesn't wait for the map, so I included a window-status condition without success:
In my html:
var myMap = L.map('myMap',{attributionControl: false, zoomControl:false })
.on('load', function(){window.status = 'maploaded'});
My options for wkhtmltopdf:
options = {
'dpi': 300,
'image-dpi': 400,
'zoom': 0.7,
'window-status': 'maploaded'
}
I check that the event is fired and the pdf is generated after it's fired, but I the map is not shown.
What should I do?