Skip to content

refactor: use descriptive namespace for json-render state key#246

Merged
antfu merged 1 commit intomainfrom
antfu/jr-internal-key
Mar 23, 2026
Merged

refactor: use descriptive namespace for json-render state key#246
antfu merged 1 commit intomainfrom
antfu/jr-internal-key

Conversation

@antfu
Copy link
Copy Markdown
Member

@antfu antfu commented Mar 23, 2026

Description

Rename the internal shared state key for json-render from the cryptic __jr:<id> to a more descriptive and properly namespaced devtoolskit:internal:json-render:<id>. This improves code clarity and reduces the risk of accidental namespace collisions with other internal state keys.

Linked Issues

None

Additional context

No breaking changes — the key is only constructed in one place and dynamically read by clients via _stateKey.

Use `devtoolskit:internal:json-render:<id>` instead of the cryptic `__jr:<id>`
for shared state keys. Improves clarity and prevents accidental namespace collisions.

Co-Authored-By: Claude Haiku 4.5 <[email protected]>
@antfu antfu merged commit 2d5befc into main Mar 23, 2026
7 checks passed
@antfu antfu deleted the antfu/jr-internal-key branch March 23, 2026 11:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant