Tagged articles
Diff Algorithm
33 articles · Page 1 of 1
This article explains why web pages feel sluggish, how React Fiber’s interruptible asynchronous rendering solves the jank problem, and walks through progressively refined implementations—from a basic React demo to a full Fiber renderer with work‑loop scheduling, diffing, and performance optimizations.
Diff AlgorithmFiberJavaScript
0 likes · 19 min read

This article investigates Vue 3.6’s new Vapor mode, comparing its compilation output with traditional Vue, revealing that while most bindings skip the virtual‑DOM and diff steps, the v‑for directive still relies on a full diff algorithm for complex list updates.
Diff AlgorithmFrontend OptimizationVapor Mode
0 likes · 9 min read

This article compares the diff and UI update mechanisms of Flutter and Jetpack Compose, explaining Flutter's Element‑based linear reconciliation and Compose's Composer‑driven SlotTable with gap‑buffer diff, while illustrating each step with code snippets and diagrams.
Diff AlgorithmFlutterJetpack Compose
0 likes · 14 min read

This article explains why using :key="index" in Vue v-for loops is problematic, describes the virtual DOM compilation process, demonstrates the diff algorithm with examples, and provides best practices for key usage to improve rendering performance.
Diff AlgorithmVirtual DOMVue
0 likes · 6 min read

QQ 9 achieves a “silky smooth” experience by cutting launch time 40% through lazy‑loaded libraries and main‑thread priority tweaks, boosting runtime fluidity with an NT Kernel that offloads logic, incremental diff refreshes and parallel layout, and adding the Hodor anti‑degradation system, delivering 35% smoother performance and 48% less lag.
Android optimizationAsync LayoutDiff Algorithm
0 likes · 20 min read

This article explains the three key differences between using a custom React component as a JSX element versus calling it as a plain function, covering extra Fiber node creation, distinct execution timing, and how the diff algorithm treats the resulting nodes.
Component vs FunctionDiff AlgorithmFiber
0 likes · 11 min read

This article explains Vue's diff algorithm in detail, covering prerequisite concepts about VNode, left‑ and right‑side comparisons, handling arrays of different lengths, and the complete implementation with code examples to help developers grasp how Vue efficiently updates the DOM.
Diff AlgorithmJavaScriptVue
0 likes · 11 min read

The article explains Vue’s virtual‑node diff algorithm, detailing depth‑first traversal, head‑tail pointer comparisons, an index‑map for moved nodes, post‑traversal addition/removal handling, and Vue 3’s static‑vnode optimization, showing how these techniques achieve efficient O(n) DOM updates.
Diff AlgorithmVirtual DOMVue
0 likes · 6 min read


政采云技术Nov 15, 2022 · Fundamentals
This article explains the internal mechanics of Git, covering its distributed nature, object model (commits, trees, blobs), branch creation, merging strategies, conflict resolution, and the Myers algorithm used for diff operations, illustrated with command‑line examples and diagrams.
Diff AlgorithmGitObjects
0 likes · 19 min read

The article explains how Vue 2’s diff algorithm uses head‑to‑tail comparisons and a key‑to‑index map to patch, add, or remove nodes, while Vue 3 improves efficiency by building a key‑to‑new‑index map, computing the longest increasing subsequence, and moving only non‑LIS nodes, reducing DOM operations.
Diff AlgorithmFrontend DevelopmentJavaScript
0 likes · 22 min read

This article explains React's Diff algorithm and Fiber architecture, compares it with Vue2 and Vue3's double‑ended diff approaches, and discusses why Vue does not need Fiber or time‑slicing, providing code examples and visual illustrations of the underlying mechanisms.
Diff AlgorithmFiberFrontend Development
0 likes · 30 min read

This article explains the design and implementation of a minimal 40‑line Diff algorithm for React’s virtual DOM, covering node attribute changes, insertions, deletions, and moves, and provides a complete TypeScript demo that marks nodes with placement or deletion flags for efficient DOM updates.
Diff AlgorithmJavaScriptReact
0 likes · 10 min read

FolderBsdp provides an efficient incremental update method for React Native hybrid apps by diffing raw resource folders per file with BSDiff, packaging tiny patches into a single ZIP, dramatically cutting bandwidth, memory usage, and storage while eliminating extra ZIP dependencies, making it ideal for low‑end devices.
Diff AlgorithmFolderBsdpReact Native
0 likes · 22 min read

This article explains the concept of virtual DOM, its advantages over direct DOM manipulation, details the diff algorithm including same‑layer comparison, pointer techniques, and longest increasing subsequence optimizations in Vue2 and Vue3, and discusses key usage and performance considerations.
Diff AlgorithmVirtual DOMVue
0 likes · 23 min read


政采云技术Feb 22, 2022 · Frontend Development
This article provides a thorough analysis of Snabbdom’s virtual DOM implementation, explaining core concepts such as vnode structure, the diff algorithm, and the patch process, and includes detailed code walkthroughs and diagrams to help developers understand and apply these mechanisms in front‑end projects.
Diff AlgorithmJavaScriptSnabbdom
0 likes · 19 min read

This article explains how to build a lightweight virtual DOM library in JavaScript, covering the creation of VNode objects, the patch and diff algorithms, handling of attributes, classes, styles, and events, and demonstrates a step‑by‑step implementation using the Snabbdom approach.
Diff AlgorithmJavaScriptSnabbdom
0 likes · 18 min read

This article explains the React Fiber architecture introduced in React 16, compares it with React 15, details how Fiber nodes form a tree, and walks through the source-level implementation of the Diff algorithm, including single-node and multi-node updates, with code examples and diagrams.
Diff AlgorithmFiberFrontend Development
0 likes · 17 min read


政采云技术Nov 2, 2021 · Frontend Development
Using an array index as the key in Vue list rendering can cause unnecessary DOM re‑creation, performance degradation, and data misalignment, especially when items are inserted, removed, or reordered, so developers should prefer stable, unique identifiers such as IDs, symbols, or UUIDs for keys.
Diff Algorithmfrontendkey
0 likes · 17 min read

This article explains the concept of virtual DOM, its structure, and how Vue's diff (patch) algorithm works, including detailed code walkthroughs, optimization strategies, key usage, and differences between Vue2 and Vue3 implementations, helping readers fully grasp the underlying principles and performance improvements.
Diff AlgorithmVirtual DOMVue.js
0 likes · 28 min read

The article thoroughly explains Vue.js’s virtual‑DOM diff algorithm, detailing its depth‑first traversal, same‑level node comparison, the sameVnode key/selector check, index map creation, O(n) head‑tail and index‑based matching loops, Vue 3 static‑type optimizations, and a practical implementation for array change detection.
Diff AlgorithmVirtual DOMVue.js
0 likes · 6 min read


ByteFEAug 19, 2021 · Frontend Development
This article provides a comprehensive technical analysis of the diff algorithm and Virtual DOM, detailing their core principles, O(n) complexity optimizations, and practical implementations across Vue 2.x, Vue 3.x, React, and the Snabbdom library.
DOM ReconciliationDiff AlgorithmReact
0 likes · 24 min read


ByteFEJul 15, 2021 · Frontend Development
This article explains what the Virtual DOM is, why it improves performance, how React implements it through ReactElements and Fiber, and details the diff algorithm and reconciliation process that enable efficient UI updates in modern frontend development.
Diff AlgorithmFiberReact
0 likes · 28 min read

This article explains how the O2 CodeReview tool, built on a pure‑frontend IDE, determines the appropriate merge‑base using Git data, handles multiple branch scenarios, and implements a version‑skip algorithm to reduce review workload while ensuring correct diff information.
Diff Algorithmcode reviewfrontend IDE
0 likes · 15 min read

This article explains how IDE‑based code review tools can compute the correct merge‑base using Git commit data, handle complex branch scenarios, and implement a version‑skip algorithm that reduces review workload while ensuring accurate diff information.
Diff AlgorithmGitIDE integration
0 likes · 17 min read

This article explains the purpose of the key attribute in Vue, demonstrates why using the array index or random numbers as keys breaks the virtual‑DOM diff algorithm, and provides best‑practice recommendations for stable, unique keys to ensure efficient component updates.
Diff AlgorithmVue.jsfrontend performance
0 likes · 12 min read

This article explains the Virtual DOM concept, outlines a state‑driven rendering approach, implements a minimal Virtual DOM (VD) structure, creates a diff algorithm to generate patch objects, applies those patches to the real DOM, and compares its performance with full re‑rendering.
DOM PatchingDiff AlgorithmFrontend Development
0 likes · 8 min read

The article explains the Virtual DOM as a lightweight JavaScript object with tag, props, and children, shows how JSX compiles to VD using a custom pragma, provides helper functions to create real DOM from VD, and outlines how batching updates reduces reflows, previewing a future diff algorithm.
Diff AlgorithmFront-endJSX
0 likes · 7 min read

The article details Ctrip's engineering solution for incremental offline package updates in its travel app, covering package creation, management, differential patch generation, download strategies, installation, monitoring, and practical challenges to achieve high success rates on iOS and Android.
Diff Algorithmdeploymentincremental update
0 likes · 13 min read

This article delves into React’s diff mechanism, explaining how the framework transforms the naïve O(n³) tree‑edit distance into an O(n) solution through layered tree diff, component diff, and element diff strategies, and offers practical insights on key usage and performance pitfalls.
Diff AlgorithmReactfrontend performance
0 likes · 14 min read

React’s diff algorithm, the engine behind Virtual DOM, optimizes UI rendering by comparing tree, component, and element structures using strategies like tree diff, component diff, and element diff, enabling efficient updates that minimize DOM operations and boost performance.
Diff AlgorithmReactVirtual DOM
0 likes · 7 min read

This article explains how React’s diff algorithm works with the Virtual DOM, detailing tree, component, and element diff strategies, optimization assumptions, and practical guidelines to achieve high‑performance UI rendering while minimizing unnecessary DOM operations.
Diff AlgorithmReactVirtual DOM
0 likes · 7 min read


WeChatFEMar 22, 2016 · Frontend Development
This article explains how to implement a basic Virtual DOM algorithm in 300–400 lines of JavaScript, covering state‑management motivations, tree representation, diffing, and patching, with step‑by‑step code examples and visual illustrations to help developers understand and build their own lightweight Virtual DOM library.
Diff AlgorithmVirtual DOMdom manipulation
0 likes · 13 min read

This article surveys practical approaches for implementing real‑time collaborative editing, comparing simple edit‑lock methods, line‑based diff/patch techniques, character‑level Myer's diff, and Operational Transformation—including distributed challenges—and offers recommendations based on project size and performance needs.
Diff Algorithmconflict resolutiondistributed systems
0 likes · 16 min read
