38.4 Static analysis and lint gates

Overview and links for this section of the guide.

Linting as a Tool

Tests are expensive (they take time to run). Linting is cheap.

Run `eslint` or `ruff` immediately after generation. If there is a syntax error, feed it back to the model immediately. Do not even bother running the tests yet.

Type Checking

For TypeScript/Python, `tsc` or `mypy` are your best friends. They catch hallucinations (using non-existent methods) instantly.

Prompt: "Your code has type errors. Here is the output of `tsc`. Fix them."

Where to go next