The ability to reply to discussions is limited to PRO members. Want to join in the discussion? Click here to subscribe now.

Display Output in React with a Component's render Method

Display Output in React with a Component's render Method

1:20
The `render` method is where the magic happens in your React components to display output to the screen. This lesson explains how to structure your JSX in a React component.
Watch this lesson now
Avatar
egghead.io

The render method is where the magic happens in your React components. This lesson will introduce you to this method and its use.

Avatar
Guillermo

The reason why not putting JSX or parenthesis in the same line of the return statement will make the code fail is that JS ASI (Automatic Semicolon Insertion) mechanism, will interpret that after the return keyword, there must be a value, and if it's not present, then it will append undefined seamless ending the sentence (return undefined;).

In reply to egghead.io
HEY, QUICK QUESTION!
Joel's Head
Why are we asking?