Plants vs. Zombies Clone
Neil Haddley โข June 16, 2026
Vibe coding a vanilla JS Plants vs. Zombies clone with Claude Code, complete with Playwright visual regression tests
I spent a lazy evening vibe coding a Plants vs. Zombies clone with Claude Code. The whole game lives in a single vanilla JavaScript file running on an HTML5 canvas โ no frameworks, no build step โ with sprites pulled from the UnityPlantsVsZombiesClone repo and the official Plants vs. Zombies wiki. I had Claude Code set up a Playwright-based visual regression test that screenshots the running game and compares it pixel-by-pixel against reference images, so I can keep adding plants and zombies without breaking the layout.
I recorded a demo video of the peashooter, sunflower, and wallnut fighting off zombies



