If you've ever tried to turn a modern web page into a PDF programmatically, you've probably hit the wall: the file comes out blank, half-empty, or frozen on a loading spinner. The page looks perfect in the browser, so what gives? The answer is timing.
Source: [Dev.to](https://dev.to/petr_savenok/converting-a-javascript-rendered-web-page-to-pdf-4nd5)