I have problems with my layout, when I re-size window manually and restore it to normal everything is in the perfect place.
Is it possible to trick the browser and
Since then a better solution has been posted in https://stackoverflow.com/a/18693617/2306587:
window.dispatchEvent(new Event('resize'));