Repository navigation
Convert remaining $effect misuse to derived values and event handlers - #1555
Conversation
…closes #1511) Replaces the deferred title-sync effect (tick().then() hack around state_unsafe_mutation) with a derived title pushed via untrack(), matching the pattern already used correctly in query-node-viewer.svelte. Converts the read-and-write reloginDismissed effect into a per-episode counter on ProSyncStore so dismissal state no longer needs to read and reset itself. Moves the sidebar sub-panel dismissal out of an effect and into the one handler that can trigger it. Replaces the autoOpen prop->state mirror with a one-time initial value, matching the component's actual remount lifecycle. Co-Authored-By: Claude <[email protected]>
Code Review SummaryThis PR does what it says: seven FindingsSuggested Improvements
Nitpicks
Verification performed
RecommendationApprove with the one suggested follow-up (test coverage for |
|
Review verdict: Approve (net positive, low risk). GitHub won't let me submit a formal self-review approval on my own PR ( |
- Adds 4 unit tests against ProSyncStore covering the episode-counter transition logic added in the prior commit: bumps on entry into auth-required, does not re-bump on redundant re-delivery of the same state, bumps again on a distinct re-entry, and bumps correctly when the transition arrives via tier-detected's initial_status payload. - Adds a one-line comment at the GenericSchemaForm render site documenting why capturing autoOpen once at mount is safe (depends on genericSchema being fully resolved before that branch ever renders). Skipped: the reviewer's nit about collection-node-viewer.svelte's data-load effect missing untrack() is a pre-existing gap in code this PR didn't touch — out of scope for #1511, left for a follow-up. Co-Authored-By: Claude <[email protected]>
Addressed review feedback✅ Addressed:
⏭️ Skipped:
Verification:
Re-Review DecisionDecision: NO RE-REVIEW NEEDED Rationale: Changes are additive test coverage plus a documentation comment — no logic changes to the reviewed diff, no new risk surface. The prior review already verified the |
Closes #1511