Skip to content

Commit 8d88821

Browse files
authored
Merge pull request #161 from ivaneroshkin/virtual-dom
Translate "Virtual DOM"
2 parents 0492de3 + aa08fdb commit 8d88821

File tree

7 files changed

+9
-9
lines changed

7 files changed

+9
-9
lines changed

content/docs/faq-internals.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
---
22
id: faq-internals
3-
title: Virtual DOM and Internals
3+
title: Виртуальный DOM и детали его реализации в React
44
permalink: docs/faq-internals.html
55
layout: docs
66
category: FAQ
77
---
88

9-
### What is the Virtual DOM? {#what-is-the-virtual-dom}
9+
### Что такое виртуальный DOM? {#what-is-the-virtual-dom}
1010

11-
The virtual DOM (VDOM) is a programming concept where an ideal, or "virtual", representation of a UI is kept in memory and synced with the "real" DOM by a library such as ReactDOM. This process is called [reconciliation](/docs/reconciliation.html).
11+
Виртуальный DOM (VDOM) — это концепция программирования, в которой идеальное или «виртуальное» представление пользовательского интерфейса хранится в памяти и синхронизируется с «настоящим» DOM при помощи библиотеки, такой как ReactDOM. Этот процесс называется [согласованием](/docs/reconciliation.html).
1212

13-
This approach enables the declarative API of React: You tell React what state you want the UI to be in, and it makes sure the DOM matches that state. This abstracts out the attribute manipulation, event handling, and manual DOM updating that you would otherwise have to use to build your app.
13+
Такой подход и делает API React декларативным: вы указываете, в каком состоянии должен находиться пользовательский интерфейс, а React добивается, чтобы DOM соответствовал этому состоянию. Это абстрагирует манипуляции с атрибутами, обработку событий и ручное обновление DOM, которые в противном случае пришлось бы использовать при разработке приложения.
1414

15-
Since "virtual DOM" is more of a pattern than a specific technology, people sometimes say it to mean different things. In React world, the term "virtual DOM" is usually associated with [React elements](/docs/rendering-elements.html) since they are the objects representing the user interface. React, however, also uses internal objects called "fibers" to hold additional information about the component tree. They may also be considered a part of "virtual DOM" implementation in React.
15+
Поскольку «виртуальный DOM» – это скорее паттерн, чем конкретная технология, этим термином иногда обозначают разные понятия. В мире React «виртуальный DOM» обычно ассоциируется с [React-элементами ](/docs/rendering-elements.html), поскольку они являются объектами, представляющими пользовательский интерфейс. Тем не менее, React также использует внутренние объекты, называемые «волокнами» (fibers), чтобы хранить дополнительную информацию о дереве компонентов. Их также можно считать частью реализации «виртуального DOM» в React.
1616

17-
### Is the Shadow DOM the same as the Virtual DOM? {#is-the-shadow-dom-the-same-as-the-virtual-dom}
17+
### Теневой DOM похож на виртуальный DOM? {#is-the-shadow-dom-the-same-as-the-virtual-dom}
1818

19-
No, they are different. The Shadow DOM is a browser technology designed primarily for scoping variables and CSS in web components. The virtual DOM is a concept implemented by libraries in JavaScript on top of browser APIs.
19+
Нет, они совсем разные. Теневой DOM (Shadow DOM) — это браузерная технология, предназначенная в основном для определения переменных и CSS в веб-компонентах. Виртуальный DOM – это концепция, реализованная библиотеками в JavaScript поверх API браузера.
2020

21-
### What is "React Fiber"? {#what-is-react-fiber}
21+
### Что такое «React Fiber»? {#what-is-react-fiber}
2222

23-
Fiber is the new reconciliation engine in React 16. Its main goal is to enable incremental rendering of the virtual DOM. [Read more](https://github.com/acdlite/react-fiber-architecture).
23+
Fiber – новый механизм согласования в React 16, основная цель которого сделать рендеринг виртуального DOM постепенным. [Узнать больше](https://github.com/acdlite/react-fiber-architecture).

gatsby-config.js

100644100755
File mode changed.

src/components/CodeEditor/CodeEditor.js

100644100755
File mode changed.

src/components/ErrorDecoder/ErrorDecoder.js

100644100755
File mode changed.

src/components/LayoutFooter/Footer.js

100644100755
File mode changed.

src/components/TitleAndMetaTags/TitleAndMetaTags.js

100644100755
File mode changed.

src/pages/index.js

100644100755
File mode changed.

0 commit comments

Comments
 (0)