惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

腾讯CDC
博客园 - Franky
MyScale Blog
MyScale Blog
L
LangChain Blog
Martin Fowler
Martin Fowler
Recent Announcements
Recent Announcements
Stack Overflow Blog
Stack Overflow Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
博客园 - 司徒正美
量子位
A
About on SuperTechFans
C
Check Point Blog
大猫的无限游戏
大猫的无限游戏
Last Week in AI
Last Week in AI
小众软件
小众软件
Apple Machine Learning Research
Apple Machine Learning Research
I
InfoQ
V
Visual Studio Blog
Vercel News
Vercel News
B
Blog
爱范儿
爱范儿
aimingoo的专栏
aimingoo的专栏
U
Unit 42

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
React Rn-Rendering Wrokflow
Ankit Singh · 2026-05-02 · via DEV Community
Cover image for React Rn-Rendering Wrokflow

Ankit Singh

In this blog I am going to share my personal analysis of React re-render workflow. there are mainly 3 core steps (plus browser paint), let me tell you in very simple words what all these steps do:

Step 1. Trigger – basically it is when React triggers a render. There can be many ways to trigger, for example:

  1. state change
  2. props change
  3. context change
  4. parent re-render

Note: React does not immediately update DOM here, it just schedules an update.

Step 2. Render Phase – here Fiber engine comes into the picture. It handles reconciliation of new changes.
Basically it:

  1. calls components and creates new React elements (Virtual DOM concept)
  2. compares it with previous output using reconciliation (diffing)
  3. decides what needs to update, delete, or create

Note: This phase is pure computation (no DOM updates)
It can be paused, restarted, or interrupted (Concurrent React)
React builds a Fiber tree to track and manage updates
React may skip re-rendering of components if props/state did not change (bailout optimization)

Step 3. Commit Phase – after render phase, commit phase starts. This phase cannot be stopped. Once React has final changes, it directly updates the real DOM.

In this phase:

  1. DOM mutations happen
  2. refs get updated
  3. cleanup of previous effects runs
  4. useLayoutEffect runs (synchronously, before paint)

Note: this phase is fast and blocking.

Step 4. Browser Paint – once DOM is updated, browser paints the UI on screen.

After paint:

  1. useEffect runs (async, non-blocking)

Note: That’s why useEffect does not block UI, but useLayoutEffect can.

Here is an example with explanation:

function Counter() {
  const [count, setCount] = useState(0);

  return (
    <button onClick={() => setCount(count + 1)}>
      {count}
    </button>
  );
}

Enter fullscreen mode Exit fullscreen mode

when button clicked:

  1. Trigger: setCount called
  2. Render Phase: React creates new elements and compares with previous ones
  3. Commit Phase: button text updated in real DOM
  4. Browser Paint: UI shows new count
  5. useEffect (if any) runs after paint
  6. React may skip DOM update if output is same (optimization)

Some important points:

  • Re-render does not always mean DOM update
  • Parent re-render can trigger child re-render
  • React batches multiple state updates
  • Keys are important for list rendering
  • In Strict Mode, React may render twice (dev only)
  • Render phase can run multiple times, but commit runs once per update