swinton / screenshot-website

:camera_flash: A GitHub Action to capture screenshots of a website, across Windows, Mac, and Linux

Home Page:https://git.io/screenshot-website

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dynamic URLs from Netlify preview

LukaHarambasic opened this issue · comments

Hi,

I wanted to ask if you know if it's possible to combine this action with the default Netlify setup.

Netlify hosts a preview of the current build, that's linked in every new PR. Now I want to have screenshots from this preview on multiple screen sizes. Do you know if that's possible?

Thanks,
Luka :)

Hi @LukaHarambasic. Thanks for the question. I believe it should be possible. I think all you would need to know is the dynamic URL from Netlify. Is there a way to get that from the Netlify API?

Actually it looks like you can get the Netlify "deployment URL" via an output from this action:

https://github.com/marketplace/actions/netlify-actions

So you could take that output and plug it in to this action as an input.

Please let me know if you get this working. I may add it to the docs for this repo.