zinserjan / wdio-screenshot

A WebdriverIO plugin. Additional commands for taking screenshots with WebdriverIO.
MIT License
109 stars 43 forks source link

argument order for chaining support #73

Open webOS101 opened 7 years ago

webOS101 commented 7 years ago

Curious why the argument order is different from current webdriverio commands? Changing the selector order around could allow for element chaining. E.g.:

browser.element('#myDiv').saveElementScreenshot('myFile.png')
zinserjan commented 7 years ago

Good question. I think I did this to keep them more similar to the other screenshot commands. So there's no real reason for this.

Can you verify that this will work when we just switch the order of them?

webOS101 commented 7 years ago

I can't promise to get to this in a timely manner but I will see if I have time this weekend.