Run Chrome Dev tools commands programatically in console to take node screenshots

Viewed 293

I'm looking for a way to programatically take screenshots of multiple HTML nodes on a page. Under console you can take a screenshot by doing Command + Shift + P > Capture node screenshot.

Does Dev tool have an equivalent command for the same? Something like:

nodes.forEach( ( node ) => Chrome.api.commands.nodeScreenshot( node ) );

where nodes is a NodeList.

0 Answers
Related