Need help?
<- Back

Comments (44)

  • CyberShadow
    Same, I've added a .#screenshots derivation. High up-front effort but almost zero maintenance afterwards.Bonus: since you're generating screenshots programmatically anyway, you can generate a pair of each with your app's light/dark theme, and swap them in/out depending on prefers-color-scheme: dark. <picture> elements work in GitHub READMEs, too: https://github.com/CyberShadow/CyDo#readme
  • Nashooo
    Hey, you need to make your code examples horizontal scrollable on mobile! I could still guess their content based on context clues but still.
  • furyofantares
    Very cool.For the small casual games I've been vibe coding, I always start from a place where the application has a CLI where it can run headless, rendering to offscreen texture, with a a screenshot command as well as performance instrumentation. It takes no time to include all this, and gives the agent a way to automate the ui and inspect important things. It also lets me trivially have the agent update screenshots.Not as neat as being part of the build process, but I will now add that.
  • merelysounds
    This is very useful in mobile projects.App stores require screenshots, but generating N images for NUMBER_OF_SCREEN_SIZES times NUMBER_OF_LOCALIZATIONS can be a chore.In the past I wrote my own scripts for that, today tools like Fastlane[1] help.I use Fastlane for my logic puzzle game Nonoverse[2], you can see sample screenshots in its App Store page.I also automated App Preview video recording, complete with multiple scenes. If anyone wants to read more let me know, perhaps this is a good topic for an article.[1]: https://fastlane.tools/[2]: https://apps.apple.com/us/app/nonoverse-nonogram-puzzles/id6...
  • ekjhgkejhgk
    > Your users might not notice, but you know, and it gnaws at you.The users WILL DEFINITELY notice if the screenshots don't match what they have in front of their eyes.
  • Mackser
    Super cool! Love that you can declare the screenshots inline in the markdown document.For my desktop app I created a solution that generates screenshots in multiple languages, light/dark mode, removes noise and adds Windows/macOS window frames.Wrote about it here: https://maxschmitt.me/posts/cakedesk-website-redesign#screen...It's currently a separate script (which is a pain to maintain). I should look into making it a part of the markdown/mdx. Thanks for the inspiration!
  • LeoDaVibeci
    I've needed this so many times. BTW this should be a meme: "I think this might be the neatest thing I’ve built in X that nobody will ever notice."
  • schneems
    This is neat. I wrote https://github.com/zombocom/rundoc. It has a similar feature. The main driver is to produce tutorials so it also puts the output of commands run back in the document.
  • cocoto
    Wouldn’t a real live render approach work in this case? Have a live preview of your tool inside a rectangle. If the tool is light it should be optimal visually: it will respect browser rendering settings like accessibility parameters or custom addons.
  • taspeotis
    I’ve wondered about doing screenshots from the e2e test run, even keeping docs/ all together in the same repo so when you update the documentation and need a new screenshot you add a new test
  • npodbielski
    I do not know why but looking at the title I was sure that this involves something like webserver that updates static file it serves by some external webhook.
  • dhruv3006
    This is very cool - I think I will try having this in https://voiden.md/.
  • maderalabs
    Nice! I actually started to build this exact thing a couple years back, and ended up abstracting it out to something more generic with https://picshift.io/. That said, I still love the screenshot use case - the original name of this project was ScreenSync ;)
  • borplk
    Site appears to be down intermittently with a Django errorIf author sees this: Turn off Django debug mode
  • efortis
    same here, but linking to the screenshots used for pixel diffing, which get committed to the repo.https://github.com/ericfortis/mockaton/tree/main/pixaton-tes...
  • kalb_almas
    I'm sometimes gettingNoMethodError at /self-updating-screenshots undefined method `name' for nil:NilClassRuby title-for: in handle, line 12 Web GET interblah.net/self-updating-screenshotsfollowed by a very detailed traceback when I try to access the page
  • xp84
    Bravo. This is incredibly useful, and really improves the quality of documentation, especially for many applications whose design and UI are always in flux.
  • willm
    I approve of this approach.The docs for Textual (TUI library for Python) build screenshots along with the docs. Technically not really screenshots, they are SVGs, but principle is the same. They never get out of date.https://textual.textualize.io/widgets/markdown/#example
  • bobek
    Plus we had a visual diff on the top of that as a part of the CI pipeline. It prevented a bunch of mishaps ;)
  • Biganon
    You should set DEBUG=False in your Django settings.
  • est
    I maintain an internal wiki, the contents were generated by each CI/CD and always reflects from latest running code.
  • sublinear
    Why wouldn't you want to version the screenshots along with the text? That's a feature, not a bug.At best, this seems to require an unpublished draft state for all automatic screenshot updates until explicitly approved so that mistakes don't leak out to everyone else.At worst, this is an unrealistic level of discipline to keep things in sync that is far greater than just updating the docs normally with the next major version release.My alternative suggestion would be to make sure your test suite takes screenshots with every build. They're already perfectly organized and in the context of what you're documenting.
  • davidtio
    Interesting app, definitely will reduce a lot of work updating documentation.
  • boxed
    For web projects, consider not doing screenshots at all and just embedding the html: https://kodare.net/2025/01/14/iframes-not-screenshots.htmlYou can get responsive design in "screenshots" with this. Super nice, and people can copy paste, look at the code (useful for dev tools), etc.
  • 3eb7988a1663
    shot-scraper is another project in this vein.https://github.com/simonw/shot-scraper
  • erikmay
    Awesome! Now you could even go a step further and add satori to the pipeline to add content to the the fresh screenshot. This way annotation could be easily added to the screenshot.
  • irishcoffee
    I wrote a gui app once that ran on a safety-critical platform. I ended up stuffing a rendering of the gui (rendered offscreen) into shmem at I think 24hz, and rendered that screenshot into the safety critical application. I passed clicks (no typing for this gui) back from the statically rendered image updating on a cadence, to the offscreen GUI.Worked well. Not quite the same as this, but that’s what this reminds me of.
  • devmor
    Really love this, it should be standard practice!
  • immanuwell
    nice, embedding the capture instructions right in the markdown as comments is a dead-simple solution that'll age way better than any fancy external tooling
  • TranspectiveDev
    [dead]
  • Xmd5a
    > Then you change the UI slightly – tweak a colour, move a button, update some copy – and suddenly every screenshot that includes that element is stale. You know they’re stale. Your users might not notice, but you know, and it gnaws at you.FRelated: Sabotaging projects by overthinking, scope creep, and structural diffing – https://news.ycombinator.com/item?id=47890799