
Your Login Script Breaks Every 2 Weeks
You wrote a Playwright login script for your screenshot automation. It fills in the email, clicks the password field, types the password, clicks "Sign in." It worked on Monday. By Wednesday the CSS class changed and the selector broke. You fixed it. Two weeks later the login page added a CAPTCHA. Script breaks again. Another two weeks. They added an OAuth consent screen. The login now redirects to a third-party domain. You're maintaining a 60-line login function that breaks more often than the screenshots it's trying to capture. The alternative: just log in once Heroshot takes a differnt approach. Instead of scripting the login, you do it yourself in a real browser: npx heroshot config This opens a browser. You navigate to your app, log in however you normally would (password, Google SSO, magic link, YubiKey, whatever), and then start picking elements for screenshots. When you're done, heroshot saves the browser session encrypted: .heroshot/session.enc Next time you run npx heroshot ,
Continue reading on Dev.to Webdev
Opens in a new tab



