freeCodeCamp/guide/russian/certifications/front-end-libraries/react/render-html-elements-to-the.../index.md

20 lines
677 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

---
title: Render HTML Elements to the DOM
localeTitle: Выделение HTML-элементов в DOM
---
# Выделение HTML-элементов в DOM
Чтобы отобразить элемент в DOm, мы используем следующий синтаксис
```javascript
ReactDOM.render(<item to be rendered>, <where to be rendered>);
```
## Решение
Следуя синтаксису, мы добавили бы эту строку кода, чтобы отобразить элемент JSX в div с идентификатором узла-вызова.
```javascript
ReactDOM.render(JSX,document.getElementById('challenge-node'));
```