DEV Community

Discussion on: How to easily render multiple elements in React

Collapse
 
blackr1234 profile image
blackr1234 • Edited

You don't need to write <React.Fragment>. Just wrap your multiple components in an empty tag <>...</>, it's the same.

Collapse
 
napoleon039 profile image
Nihar Raote

Yes, that's the new syntax and is mentioned in the docs, which is why I didn't mention it. I'll add it in as well then.