Repository navigation
Support for custom props and middleware - #418
Merged
Merged
Conversation
mme
enabled auto-merge (squash)
July 3, 2024 09:19
johannhartmann
pushed a commit
to johannhartmann/CopilotKit
that referenced
this pull request
Oct 31, 2025
* add custom properties * add onBeforeRequest handler * add after request middleware * customProperties -> properties * move hooks to middleware prop * update API and fix docs
johannhartmann
pushed a commit
to johannhartmann/CopilotKit
that referenced
this pull request
Oct 31, 2025
* add custom properties * add onBeforeRequest handler * add after request middleware * customProperties -> properties * move hooks to middleware prop * update API and fix docs
1 of 3 tasks
jpr5
added a commit
that referenced
this pull request
Apr 29, 2026
## Summary
- Remove conditional early return in `TallyTrigger` that rendered
different DOM structures on server vs client (bare `<>{children}</>` vs
`<div><button>{children}</button></div>`)
- All hooks now run unconditionally; interaction is disabled via guards
when items array is empty
- Fixes React errors #418 (hydration mismatch) and #310 (fewer hooks
rendered) that crash the dashboard on load
## Test plan
- [x] 10 existing tally-breakdown tests pass (updated for always-wrapper
behavior)
- [ ] Dashboard loads without crash at `#matrix:depth,health`
- [ ] Tally breakdown tooltips work on hover/click for non-empty buckets
1 of 4 tasks
jpr5
added a commit
that referenced
this pull request
Apr 29, 2026
…#4402) ## Summary - `useOverlays` hook read URL hash + localStorage in `useState` initializer, producing different DOM on server vs client → React #418 - `useCollapsible` hook read localStorage in `useState` initializer → same issue - Both now initialize with server-safe defaults and sync from client state in `useEffect` after hydration ## Test plan - [x] 338 tests pass - [ ] Dashboard loads at `#matrix:depth,health` with zero console errors - [ ] Overlay state persists correctly (URL hash + localStorage) - [ ] Collapsible category state persists across reloads
zeekay
pushed a commit
to Dream-AI-4444/CopilotKit
that referenced
this pull request
Sep 11, 2026
Remove conditional early return that rendered different DOM structures on server vs client (bare fragment vs div>button wrapper). All hooks now run unconditionally; interaction is disabled via guards when items array is empty. Fixes React errors CopilotKit#418 and CopilotKit#310.
zeekay
pushed a commit
to Dream-AI-4444/CopilotKit
that referenced
this pull request
Sep 11, 2026
…tKit#4399) ## Summary - Remove conditional early return in `TallyTrigger` that rendered different DOM structures on server vs client (bare `<>{children}</>` vs `<div><button>{children}</button></div>`) - All hooks now run unconditionally; interaction is disabled via guards when items array is empty - Fixes React errors CopilotKit#418 (hydration mismatch) and CopilotKit#310 (fewer hooks rendered) that crash the dashboard on load ## Test plan - [x] 10 existing tally-breakdown tests pass (updated for always-wrapper behavior) - [ ] Dashboard loads without crash at `#matrix:depth,health` - [ ] Tally breakdown tooltips work on hover/click for non-empty buckets
zeekay
pushed a commit
to Dream-AI-4444/CopilotKit
that referenced
this pull request
Sep 11, 2026
…CopilotKit#4402) ## Summary - `useOverlays` hook read URL hash + localStorage in `useState` initializer, producing different DOM on server vs client → React CopilotKit#418 - `useCollapsible` hook read localStorage in `useState` initializer → same issue - Both now initialize with server-safe defaults and sync from client state in `useEffect` after hydration ## Test plan - [x] 338 tests pass - [ ] Dashboard loads at `#matrix:depth,health` with zero console errors - [ ] Overlay state persists correctly (URL hash + localStorage) - [ ] Collapsible category state persists across reloads
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.
Uh oh!
There was an error while loading. Please reload this page.