Lint Packkit's own source (eat our own cooking)#20
Merged
Conversation
Packkit generated publint, strict TS, and lint gates for other people's packages but ran none on itself. It now lints its own source with the same stack it generates for users — eslint flat config + @eslint/js — via `npm run lint`, a `check` script (lint + test), and a CI lint job. It immediately paid off, catching real issues on the first run: - a duplicate `minify` key in the CLI arg parser (src/cli/args.js) — a genuine defect the parser silently tolerated; - dead vars/imports: an always-empty `expectApi`, an unused `toJson` import, an unused `staged` param threaded into lefthookYml, and leftover `install`/`run` locals in the monorepo generators. All fixed; generation output is unchanged (verified) and `--minify` still parses. eslint is clean, 87 tests pass. Full `tsc --checkJs` was assessed and deferred — 95 errors, almost all the "incrementally-built object literal" pattern (noise) rather than real bugs. Noted in the roadmap. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
The "Packkit doesn't eat its own cooking" P0 from the architecture review. Packkit generated
publint, strict TS, and lint gates for other people's packages, then ran none on itself.It now lints its own source with the same stack it generates for users — eslint flat config +
@eslint/js— vianpm run lint, acheckscript (lint + test), and a CI lint job.It earned its keep on the first run
ESLint found 16 issues immediately, including a genuine defect:
minifykey in the CLI arg parser (src/cli/args.js) —parseArgssilently tolerated it, but it's exactly the kind of thing that bites later.expectApiternary, an unusedtoJsonimport, an unusedstagedparam threaded intolefthookYml, and leftoverinstall/runlocals in the monorepo generators.All fixed. Generation output is unchanged (verified: lefthook.yml still emitted, test files present, fullstack still 37 files) and
--minifystill parses.Scope decision
Full
tsc --checkJswas assessed and deferred: 95 errors, nearly all the "incrementally-built object literal" pattern (Property 'outDir' does not exist on type {…}) — noise, not bugs. Not worth annotating around now. It did surface the deadreactEntryreference (removed in #18), which is the payoff that mattered. Recorded in the roadmap.eslint clean, 87 tests pass.
🤖 Generated with Claude Code