fix(hub): restore json-render pre-0.7 exports as deprecated aliases#122
Merged
Merged
Conversation
PR #116 removed `defineJsonRenderSpec`, `JsonRenderSpec`, `JsonRenderElement`, `JsonRenderer`, and `DevframeViewJsonRender` from `@devframes/hub` outright when json-render moved to the opt-in `@devframes/json-render` integration, breaking any consumer still importing them (unlike the `cac` adapter rename, which kept a deprecated `createCli` alias). Restore all five as deprecated compatibility shims — `defineJsonRenderSpec` stays an identity function, and `DevframeViewJsonRender" is kept as a standalone type without rejoining `DevframeDockUserEntry`, so it can't clash with `@devframes/json-render/hub`'s declaration-merged `'json-render'` registry entry. Document the migration in the 0.7 guide alongside the cac adapter section.
✅ Deploy Preview for devfra ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
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.
What
PR #116 moved json-render out of `@devframes/hub` into the opt-in `@devframes/json-render` integration and deleted `defineJsonRenderSpec`, `JsonRenderSpec`, `JsonRenderElement`, `JsonRenderer`, and `DevframeViewJsonRender` outright — unlike the `cac` adapter rename in the same release, which kept `createCli` around as a deprecated alias. Any consumer still importing the old json-render names hit a hard `SyntaxError` at module load:
```
SyntaxError: The requested module '@devframes/hub' does not provide an export named 'defineJsonRenderSpec'
```
Fix
Restore all five as deprecated compatibility shims, following the same pattern already used for `createCli`/`createCac`:
Verified `@devframes/hub`'s and `@devframes/json-render`'s `tsc --noEmit` both pass with no declaration-merge conflict, and confirmed the built `dist/index.mjs` now exports a working `defineJsonRenderSpec` again.
Checks
`pnpm lint && pnpm test && pnpm typecheck && pnpm build` all pass (updated the `tsnapi` API snapshots for the five restored exports).
This PR was created with the help of an agent.