How I Use Playwright to Catch Broken Routes Before Deploying

Throughout the past month, I’ve been building a free guitar-learning site with interactive tools and blogs among other things. At present, it has hundreds of routes, and I needed something to test the pages before deploying. So I added a small Playwright workflow. It checks every route in the sitemap, opens some pages in a browser, and runs after the production build to catch any issues. I think I’d need more than 7 tests to claim it catches all issues, but it’s quite useful for obvious deployment issues. Why I decided to add Playwright Generated 22 documents in .contentlayer ✓ Creating an optimized production build ✓ Compiled successfully ✓ Collecting page data ✓ Generating static pages
…