What are fragments?
- A way to create custom HTML elements
- A way to group multiple elements without adding an extra DOM node
- An alternative to using HTML tags for styling
- Special React components
Fragments are a way to group multiple elements without adding an extra DOM node. Fragments are useful when you want to return multiple elements from a component, but don't want to add an unnecessary container element to the DOM.
Loading...