feat: renaming refactor, make optimistic, fixes and improvements#1311
Merged
feat: renaming refactor, make optimistic, fixes and improvements#1311
Conversation
Contributor
Code reviewNo issues found. Checked for bugs and CLAUDE.md compliance. |
gbirman
commented
Feb 4, 2026
| case 'project': | ||
| return 'project'; | ||
| default: | ||
| return 'document'; // fallback |
Contributor
Author
There was a problem hiding this comment.
this was a dangerous fallback and atm item type matches entity data.type 1:1 anyways so this is a safer option + will catch type failrues in the future
gbirman
commented
Feb 4, 2026
| const pages = prev.pages.map((page) => ({ | ||
| ...page, | ||
| items: page.items.map((item) => { | ||
| // NOTE: reactivity does not seem to be a problem here so no spread is needed? |
Contributor
Author
There was a problem hiding this comment.
probably because we're calling page.items.map anyways so the items array ref changes is my guess
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.
refetchResourcescall which triggers multiple unnecessary backend api calls if we know the PATCH operation succeededTODOs:
this is just a video that shows optimistic update for channel/dss item rename from both menu and top bar
https://github.com/user-attachments/assets/6da56c85-3e76-47ee-8822-34354e4072f1
not shown: