ciena-blueplanet / ember-cli-visual-acceptance

MIT License
30 stars 12 forks source link

NightmareJS: Cutoff/blank images when outside of viewport #112

Open EWhite613 opened 7 years ago

EWhite613 commented 7 years ago

Need a more elegant solution than just having a user's initial viewport to ludicrous sizes.

Previously I tried changing Nightmare's viewport that was a bit bigger than the capture rectangle and scrolling the rectangle into view prior to the screenshot but I was having issues with the resulting image (most likely due having to wait for Nightmare to update the viewport and the promise chaining ). I have my work saved on my nightmare branch https://github.com/EWhite613/ember-cli-visual-acceptance/blob/nightmare/vendor/nightmarejs-launcher.js