GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||
GeezerVison is showing github.com — ⚡ Bolt: Optimize ProseMirror decoration widget rendering by dezren39 · Pull Request #151 · developing-today/code Conversation
Member
💡 What: The optimization refactors 🎯 Why: The previous implementation eagerly created DOM elements on every single editor transaction and used an ever-incrementing counter in the 📊 Impact: Massively reduces DOM churn, GC pressure, and layout recalculations. Cursor UI nodes are now safely recycled, achieving O(1) rendering time (where nodes are merely patched rather than completely recreated) during continuous editor typing. 🔬 Measurement: Verified by interacting with the editor - continuous typing no longer triggers massive DOM reflows inside the ProseMirror node rendering cycle. Evaluated by checking PR created automatically by Jules for task 7134201123385924548 started by @dezren39
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactionsRefactor `cursors.ts` to utilize ProseMirror's `() => HTMLElement` lazy creation factory for `Decoration.widget` and stable DOM element caching. This removes the anti-pattern of appending an incrementing `decorationGeneration` integer to the widget `key` on every transaction, which previously bypassed all caching and forced constant eager DOM node destruction/recreation, resulting in heavy GC pressure and layout thrashing. The new caching keys are uniquely tied to cursor state (clientID, head, opacity, connectionState) to guarantee that updates only happen when the underlying UI state dictates a change. Co-authored-by: dezren39 <[email protected]>
Contributor
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. Co-authored-by: dezren39 <[email protected]> Co-authored-by: dezren39 <[email protected]> Co-authored-by: dezren39 <[email protected]> Co-authored-by: dezren39 <[email protected]> Co-authored-by: dezren39 <[email protected]> Co-authored-by: dezren39 <[email protected]>
3 tasks
Member
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
Contributor
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
dezren39
deleted the
bolt/prosemirror-decoration-perf-7134201123385924548
branch
This was referenced
Closed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ReviewersNo reviewsUh oh!
There was an error while loading. Please reload this page. AssigneesNo one assignedLabels
None yet
ProjectsMilestoneNo milestoneDevelopmentSuccessfully merging this pull request may close these issues. Uh oh!
There was an error while loading. Please reload this page. 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. | ||||
| You are visitor 01402775 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |