diff --git a/client/src/pages/guide/english/react/jsx/index.md b/client/src/pages/guide/english/react/jsx/index.md index 4bb07a964d..065b107420 100644 --- a/client/src/pages/guide/english/react/jsx/index.md +++ b/client/src/pages/guide/english/react/jsx/index.md @@ -71,6 +71,37 @@ const tags = ( ); ``` +### All Tags Must Be Closed + +In HTML, there are self-closing tags such as `img`, `br`, `input`, and `hr`. + +This means that either of these methods are valid: + +```html + + + + +``` + +Self-closing (sometimes referred to as **void**) tags can be rendered with or without a closing forward slash. + +However, with JSX, _all_ tags must be closed. + +The following JSX is invalid: + +```javascript +const email = ; +``` + +Closing the `input` tag will make the JSX valid: + + +```javascript +const email = ; +``` + + ### More Information - [Introducing JSX](https://reactjs.org/docs/introducing-jsx.html)