Repository navigation
Adopt npm workspaces for Anvil - #6
Draft
PSchmiedmayer wants to merge 20 commits into
Draft
PSchmiedmayer wants to merge 20 commits into
PSchmiedmayer wants to merge 20 commits into
Conversation
Move the workspace from pnpm to npm workspaces with npm 12 and Node.js 24, use the shared ESLint and Prettier configurations from @schmiedmayerlab/grove-configurations with the grove-ts TypeScript flags, and fix every finding they report. Add the grove-ts workflow structure on the organization's shared workflows: build and test with quality, Node.js 26, Pages build, coverage and dependency review jobs, CodeQL, repository standards, the monthly link check, and a release deployment that publishes public packages to npm with Trusted Publishing and deploys the app to GitHub Pages. Pages no longer deploy on every push to main. Add the package verification, package lint, audit, Trusted Publishing and Pages scripts with their tests, knip analysis, CONTRIBUTORS.md, CITATION.cff, AGENTS.md, Dependabot as in grove-ts, and REUSE headers that name the Anvil open-source project.
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
| standards: | ||
| name: Standards | ||
| if: github.repository == 'SchmiedmayerLab/anvil' | ||
| uses: SchmiedmayerLab/.github/.github/workflows/repository-standards.yml@v0.5 |
| - name: Set up pnpm | ||
| uses: pnpm/action-setup@v6 | ||
| - name: Set up Node.js and install dependencies | ||
| uses: SchmiedmayerLab/.github/actions/setup-node-project@v0.5 |
| with: | ||
| persist-credentials: false | ||
| - name: Set up Node.js and install dependencies | ||
| uses: SchmiedmayerLab/.github/actions/setup-node-project@v0.5 |
| timeout-minutes: 10 | ||
| build-and-deploy: | ||
| name: Build and Deploy to GitHub Pages | ||
| uses: SchmiedmayerLab/.github/.github/workflows/npm-pages.yml@v0.5 |
| permissions: | ||
| contents: read | ||
| pull-requests: read | ||
| uses: SchmiedmayerLab/.github/.github/workflows/markdown-links.yml@v0.5 |
GitHub reports the repository as SchmiedmayerLab/Anvil, and the lab standards check compares citation and badge URLs with that name exactly. The citation, badges, and upstream conditions in the workflow now use it.
The identifier suffix now encodes the full random 32-bit value instead of reducing it modulo 36^4, which CodeQL reports as a biased use of a cryptographic random number.
Each workspace writes lcov source paths relative to its own folder, so files with the same name in different workspaces collide when Codecov maps them. The lcov reporters now use the repository root as the project root.
The workspace move reformats nearly every source line, so patch coverage measures the whole editor. The new tests drive the outline, inspector fields, conditions, previews, side panels, standard plugins, and the standalone example through the public editor, and exercise validation, document, and FHIR helpers directly.
The package TypeScript projects include their Vitest configurations but not the Node type definitions, so the repository root is now derived from the configuration's URL.
Tests no longer pin message wording that names a missing value, restore the clipboard and object URL stubs after each test, use fake timers for the delayed save and URL release, and declare jsdom for the standalone app tests that use it.
A contained resource without a resourceType is reported as not a value set instead of "a undefined", resource and item types take "an" before a vowel, and an item control without a code is labelled "no code" instead of "undefined".
The repository, issue, and homepage URLs and the trusted publishing fixtures now name SchmiedmayerLab/Anvil as GitHub reports it, like the citation and badges.
The labels of controls that do not fit read "an integer item" and "a url item", and the value text helper keeps its own comment.
Identifiers stay distinct across a 600-item import with a duplicated item, and the suffix encodes the smallest and largest random values in seven characters.
The validation and standard plugin messages use one helper module instead of a copy each.
Update typescript-eslint to 8.74.0 and lucide-react to 1.82.0, which are older than the seven-day cooldown. Refresh the transitive cross-spawn to 7.1.2 (GHSA-ghv9-86vm-4v8m) and minimatch to 11.0.10 (GHSA-3924-r96c-gp9w) within their existing ranges.
Carry the dependency and security updates from main into the npm workspaces. The pnpm lockfile stays removed, and the npm lockfile pins the same direct and patched versions.
1 task done
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.
♻️ Current situation & Problem
The standalone editor uses pnpm and has its own build and deployment configuration.
A shared npm workspace and validation workflow give the standalone editor and future library consumers the same build inputs.
Tracked in #5.
⚙️ Release Notes
📚 Documentation
The README gives standalone setup instructions, and the development guide covers local validation and static hosting.
✅ Testing
Verify a clean
npm ci,npm run validateandnpm run pages:buildon the candidate.Check import, editing, preview and export in the built standalone app.
Verify that release validation rejects a missing or lightweight tag, an unverified signature, a mismatched commit and a commit outside the default branch.
Code of Conduct & Contributing Guidelines