ARTICLE AD BOX
Use tooling: biome for making sure your code stays legible, with automatic rewriting of "no, not this way" code, tsc (the typescript parser) with --allow-js and --no-emit to catch actual "this code will never work" problems. And use a test framework: unit tests using Node.js, it has testing built in, read up on it, it has its own "test runner" page on the Nodejs API documentation. And use Playwright for integration testing: got a US? Then write tests that confirm things are on the page, and work the way they should when the user uses them.
And use AI to do all those things for you if you have to, then learn from what they create (and make triply sure than anything they do doesn't touch your code. They're a tool. Not a coworker, not another dev, they're a tool, use then as such: make them set up your linting, correctness checking, and test framework. Then you pad that out because that's how you learn).
