Fix/reactive auth sharing persist#48
Open
gitmibrahim wants to merge 8 commits into
Open
Conversation
Author
|
@rodindev Just a quick reminder to request a review on this PR when you're ready so we can get it processed. Thanks! |
rodindev
requested changes
Jun 30, 2026
rodindev
left a comment
Owner
There was a problem hiding this comment.
Thanks for this. The shared Map<specName, Ref> is the right approach. I synced your branch with main (1.8.0 is out) and CI is green. Left a few inline notes, the watch one is the only blocker.
rodindev
requested changes
Jul 5, 2026
rodindev
left a comment
Owner
There was a problem hiding this comment.
Thanks! The previous comments are all addressed nicely.
CI is red though, AuthControls.spec.ts fails on the “clears stored credentials” test.
Sould be a small fix – almost there 🙂
Author
|
@rodindev Thanks for the review. Is there still a blocker here? |
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
Shared Reactive Auth State (
packages/core/src/runtime/auth.ts):authStoresCacheandgetAuthStore).onMountedimport.auth.spec.tsto verify state sharing across multiple hook instances.Immediate Credential Persistence (
packages/core/src/components/AuthControls.vue):@input="commit"handling on the credential input field to persist modifications instantly.AuthControls.spec.tsconfirming immediate persistence on input events.Request Authorization Tests (
packages/core/src/components/EndpointTryPanel.spec.ts):beareroauth2basicapikey(header, query, and cookie locations)Why
Closes #46
useAuthStatehook maintained its own independent state. If multiple playground or auth control components were active for the same spec, a credential update in one would not reactively propagate to others in real-time. Shared caching ensures perfect UI synchronization.input) ensures that API try-it requests and code snippets are dynamically updated without forcing the user to press Enter or trigger ablurevent by clicking elsewhere first.How to test
npm run typecheckpassesnpm run test:runpassesnpm run dev