Automate screenshots
Create a Github action to take screenshots of the new profile.
When a new user want to add a new profile, they create an issue with the title add|eddiejaoude
Then a github action starts on new issues that it's name beginning with add| and take a screenshot of the username profile and add it in a comment.
If the profile is ok, you (repository maintainer) create a new comment (for example: @add-profile) and a github action starts and add the profile to README.
I don't know if this possible or not 😁.
Example for takeing a screenshot using puppeteer:
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch();
const page = await browser.newPage();
page.setViewport({
width: 2000,
height: 2000,
});
await page.goto('https://github.com/eddiejaoude', { waitUntil: 'networkidle2' });
await page.screenshot({
path: 'example.png',
clip: {
x: 380,
y: 360,
width: 1230,
height: 830,
},
});
await browser.close();
})();
Resources:
Interesting idea 👍
Alternative for screenshots https://www.npmjs.com/package/url-to-screenshot
Cypress is another tool we could use https://docs.cypress.io/api/commands/screenshot
Stale issue message
Stale issue message
btw I tried puppeteer screenshots in #672 but it didn't even work in gitpod, not sure how to make it work in GH actions 🤔
Stale issue message
What has to be done about this? Wait till, the nextjs update?
I don't think this needs to wait until the NextJS upgrade