The line below lets playright wait for 100ms to load the page before it does a print screen.
|
await page.wait_for_timeout(100) |
For small documents this might be enough, but I've encountered various notebooks that were not properly represented due to the page not being fully loaded.
I suggest to add an argument/config such that this value can be adjusted by the user.