New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Add automated screenshots for starter projects #223
Comments
Where would Pupeteer run? |
I think thumbnails to add visual interest to the catalog would be great. Though re-rendering them on every site build feels very heavy. Maybe this could be a pre-build step, as with Zach's use of Grunt on his site, or Gulp on many. |
Okay, so running on the developer's machine instead as part of a CI? |
¯_(ツ)_/¯ there's a trade-off to be made between generating thumbnails as a "dev-time" activity vs. part of the build process. I guess it depends on how builds are performed (e.g. are there processing time costs, is puppeteer available…). I do worry about introducing a build manager tot his project because it implies a standard, but that's a terrible reason to avoid pre-processing. |
NPM comes with kinda one: run-scripts. It works okay for me. So I stick to npm run-scripts and rollup, in case I need a bundler. :-) |
We do have a screenshots script in place although I don’t think it runs for starters yet!
|
Ah ok I see now there’s a screenshot generation step. Will try to update the PR to integrate starter screenshot generation into that. |
hi @zachleat @gerwitz and team,
First off, keep up the amazing work and looking forward to v1!
This is a proposal. What do you folks feel if the list of starter projects had automatically generated screenshots per entry.
I was thinking of using
puppeteer
(headless Chrome driver) to generate screenshots for the demo sites at build time. Pictures really add a lot of value e.g. Hugo Theme Gallery.I have a working prototype but wanted to gather thoughts before going too far: PR, Demo.
I am no CSS expert - so I am totally open to styling and other presentation tweaks.
Eventually this idea can also be extended to Source Code Samples.
The text was updated successfully, but these errors were encountered: