Unify FHIR package patching via preprocessPackage hook#84
Merged
Conversation
- Add preprocessPackage option to APIBuilder constructor, passed to CanonicalManager config for unified resource/package preprocessing - Remove patchSd from Register type and implementation, replaced by the preprocessPackage hook at the canonical manager level - Update @atomic-ehr/fhir-canonical-manager to ^0.0.21
- nodge-r4: Replace direct CanonicalManager construction with APIBuilder, using preprocessPackage for package name fixes and dependency injection - typescript-ccda: Replace registerFromPackageMetas + patchSd with shared CanonicalManager using preprocessPackage for IVL_TS URL fix
Top-level example files were not covered by the existing examples/*/*.ts glob pattern.
cb40ba5 to
d2fb590
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.
Summary
preprocessPackagehook (discriminated union withkind: "package" | "resource") throughAPIBuilder, allowing users to preprocess both package.json and individual resources from a single callbackpatchSdfromRegister— resource patching now happens at the canonical manager level viapreprocessPackagenodge-r4andtypescript-ccdaexamples to use the new unified hook instead of directCanonicalManagerconstruction /patchSdDepends on: atomic-ehr/fhir-canonical-manager#7
Test plan
bun run typecheckpassesbun run lintpassesbun testpasses (194 tests)make allpasses (all example pipelines generate successfully)🤖 Generated with Claude Code