feat: add javascript, css, and html checker groups - #24
Merged
Merged
Conversation
Brings the polyglot root baseline into this package: eslint:recommended, typescript-eslint recommended, react/react-hooks/jsx-a11y for JSX and TSX, eslint-config-prettier last, Prettier with its defaults, and stylelint with stylelint-config-standard plus stylelint-config-standard-scss. Node comes from the nodejs-wheel PyPI package, so consuming repos need no system Node and the hooks keep sharing one Python virtualenv. The npm tools that pip cannot install are pinned in a bundled package-lock.json and installed with `npm ci` into `polymath-node/` under sys.prefix. That is the pre-commit-managed venv, so the install is per hook revision, shared by every repo on the machine, and never lands in a consuming repo's tree. A digest stamp skips the reinstall and an flock serializes pre-commit's parallel batches. Next and Storybook rules are opt-in through a repeatable `--framework` argument, because rules like @next/next/no-img-element misfire on repos that do not use those frameworks, while polyglot needs them to keep its current coverage. ESLint is pinned to 9 rather than 10: typescript-eslint accepts both, but 10 is weeks old and the plugin ecosystem has not settled. TypeScript stays on 5.9 because typescript-eslint's peer range is <6.1.0. Two consumer-environment escapes are closed. Prettier runs with `--no-editorconfig`, because an `.editorconfig` in the consuming repo overrides indent and line width even when `--config` names an absolute file, so `[*] indent_size = 4` would silently reformat every CSS, TSX, and HTML file to 4 spaces. And `.cjs` files, which identify tags as `javascript`, get `@typescript-eslint/no-require-imports` turned off, since otherwise no `.cjs` file can ever pass. Deviations from the plan, both forced by Node's resolution rules: - `ensure_node_modules()` returns the install directory instead of its `node_modules/.bin`. The bundled tool configs are copied in beside the manifest, since Node resolves an ESLint config's bare imports and a Stylelint config's `extends` by walking up from the config file. Callers need both that directory's `.bin` and its configs. - The install stamp covers the whole bundle, not just the lockfile, so editing a tool config reinstalls. - stylelint.config.mjs keeps the CSS baseline at the root with only the SCSS override, because Stylelint rejects a config whose rules live entirely in `overrides`. `npm ci` resolved the pinned versions with no peer conflict, so no pins moved. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Signed-off-by: Emerson Knapp <emerson@polymathrobotics.com>
emersonknapp
force-pushed
the
web-checkers
branch
from
September 10, 2026 18:38
bf8936e to
b68b39f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Brings the internal polymath web-dev baseline into this package:
eslint:recommendedtypescript-eslint recommendedreact/react-hooks/jsx-a11yfor JSX and TSXeslint-config-prettierlast, Prettier with its defaults,stylelintwithstylelint-config-standardplusstylelint-config-standard-scssNode comes from the nodejs-wheel PyPI package, so consuming repos need no system Node and the hooks keep sharing one Python virtualenv.
The npm tools that pip cannot install are pinned in a bundled package-lock.json and installed with
npm ciintopolymath-node/under sys.prefix.That is the pre-commit-managed venv, so the install is per hook revision, shared by every repo on the machine, and never lands in a consuming repo's tree.
A digest stamp skips the reinstall and an flock serializes pre-commit's parallel batches.
Next and Storybook rules are opt-in through a repeatable
--frameworkargument, because rules like @next/next/no-img-element misfire on repos that do not use those frameworks, while polyglot needs them to keep its current coverage.ESLint is pinned to 9 rather than 10, which is brand new and not fully settled.
Two consumer-environment escapes:
--no-editorconfig, because an.editorconfigin the consuming repo overrides indent and line width even when--confignames an absolute file, so[*] indent_size = 4would silently reformat every CSS, TSX, and HTML file to 4 spaces..cjsfiles, whichidentifytags asjavascript, get@typescript-eslint/no-require-importsturned off, since otherwise no.cjsfile can ever pass.