Coder Social home page Coder Social logo

Comments (4)

csr632 avatar csr632 commented on May 21, 2024 2

Agreed. "New props" is confusing and doesn't have any (correct) meaning. "Parent rerenders" give infomation about "why" and "when", just like the "set­State()" and "force­Update()" labels do.

from react-lifecycle-methods-diagram.

stephan-noel avatar stephan-noel commented on May 21, 2024

Thanks for your input @csr632 ! In the meantime, I've had a colleague suggest "nextProps". Also, maybe "parent render()" would be preferable to "parent rerenders" to clarify the possible ambiguity between the React lifecycle render() method vs. the browser rendering. Not sure if Dan has any opinion about this...

from react-lifecycle-methods-diagram.

EricCoteReact avatar EricCoteReact commented on May 21, 2024

I feel that "parent render()" is perfect.

When I give a course, I use this wording:
Render: the method to generate the virtual DOM. (generates a tree structure of React Elements, which are simple js objects).
Reconcilation: the React process to update the DOM. (React does this by comparing the current vDOM with the previous one.)
Browser paint or Browser refresh: the browser process to show the DOM on the screen.

from react-lifecycle-methods-diagram.

jeffacode avatar jeffacode commented on May 21, 2024

Totally agreed! This arrow is very misleading, which confused me for quite a long time...for correctness, as long as parent component rerenders, child components should rerender as well (not if its shouldComponentUpdate returns false)

from react-lifecycle-methods-diagram.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.