Andrey (azangru) wrote,
Andrey
azangru

I am so annoyed when React people use the term "render prop" to refer to this method:

<Foo>
{ (thingy) => <Bar something={thingy}/>}
</Foo>
.

As Ryan Florence or even his holiness Dan did during this ReactConf:



It makes no sense. The original "render prop" is a prop, called "render" and used to bypass the normal component’s way of rendering by passing to it a function that it will use instead during rendering. Even React's docs still adhere to this conventional meaning by showing this prototypical example of a render prop:



The other one used to be called the "function as child" pattern. But now all the cool kids call it the render prop :-(

[Another rant]
(as an aside: you miserable LJ and your crappy editor that constantly is breaking my bit of JSX! why aren't you allowing raw code in pre tags any longer, you bastard?)
Subscribe

  • (no subject)

    To unscramble an egg, by the way, would be a closer idiomatic parallel to ungrinding ground meat, and in spite of Julia Ioffe, is just as dark, blunt…

  • (no subject)

    Thought of this phrase today for some reason, then thought whether it exists in English (putting toothpaste back into the tube came to mind), then…

  • (no subject)

    I think many (perhaps most) people are totally fine with being a free-rider, a bludger, or a sponge (remember Trump who said that he pays little…

  • Post a new comment

    Error

    default userpic
    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 0 comments