ci: add minimal workflow for typecheck and library build#72
Merged
Conversation
Adds .github/workflows/ci.yaml that runs on every pull_request and on push to main: - npx tsc --noEmit - npm run build (rollup library bundle) Node 20 LTS, npm cache enabled, in-flight runs cancelled when a new commit lands on the same ref. `npm run build-examples` is intentionally NOT run yet — examples/src/ demo.html has a pre-existing broken import that is tracked separately. A comment in the workflow points to where to re-enable the step once that is fixed. This is the safety gate that lets future PRs be auto-validated before merge.
CI failed because npx tsc could not resolve the compiler — typescript was only present transitively (via @rollup/plugin-typescript), and the bin was not reliably linked on a fresh runner. Adds typescript ^6.0.3 to devDependencies (matches the version already resolved in package-lock.json) so npx tsc and tsc --noEmit work in any clean checkout, including CI.
Adds a "typecheck" npm script and switches the CI workflow to call
`npm run typecheck` rather than `npx tsc --noEmit`.
Why: on a fresh CI runner, `npx tsc` was hitting the registry's `tsc`
stub package ("This is not the tsc command you are looking for")
instead of the local install — even with typescript declared as a
devDependency. `npm run typecheck` reliably resolves the local
node_modules/.bin/tsc.
Keep typecheck script and typescript devDep from this branch; merge in lint/format scripts and typescript-eslint from main. Regenerate package-lock.json cleanly. Co-Authored-By: Claude Sonnet 4.6 <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.
Summary
Adds
.github/workflows/ci.yamlthat runs on every pull request and on push tomain:npx tsc --noEmitnpm run build(rollup library bundle)Node 20 LTS, npm cache enabled, in-flight runs are cancelled when a new commit lands on the same ref.
Why
Without CI, every PR ships unverified. This is the safety gate that lets future work — including parallel cleanup PRs — be auto-validated before merge.
What's deliberately NOT in CI yet
npm run build-examples.examples/src/demo.htmlimports modules that don't currently exist in the repo (it's broken onmainand was already broken before this PR). A comment in the workflow file points to where to re-enable the step once that is fixed.Test plan
pull_requestNotes
🤖 Generated with Claude Code