Files
Chris Raible e0ed2e7642 Enabled lint-staged pre-commit hook on all branches (#26792)
## TL;DR

This adds a pre-commit hook that will run eslint on any JS/TS files
staged for commit, and prevent the commit from completing if there are
any errors.

## Motivation

There's nothing more annoying than raising a PR only to see the lint job
fail and having to follow up with a "fixed linter" commit. Especially as
we are not always typing out the code ourselves in our IDEs anymore,
I've been encountering these little annoyances more frequently.

## Summary

- Removed the `main`-branch-only guard from the pre-commit hook so
lint-staged runs on every commit, regardless of branch
- Expanded lint-staged file pattern from `*.js` to
`*.{js,ts,tsx,jsx,cjs}` to cover TypeScript and CJS files
- Verified lint-staged catches errors across all 16 monorepo packages
(apps/*, ghost/*, e2e)
2026-03-12 10:41:04 -07:00
..