mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-08-23 23:42:56 +02:00
add note to document documentation (#755)
can perhaps spare some time from someone else wondering about this: https://github.com/ianstormtaylor/slate/issues/746
This commit is contained in:
@@ -7,7 +7,7 @@ import { Document } from 'slate'
|
||||
|
||||
The top-level node in Slate's document model.
|
||||
|
||||
Documents are made up of block nodes, inline nodes, and text nodes—just like in the DOM.
|
||||
Documents are made up of block nodes, inline nodes, and text nodes—just like in the DOM. Note that direct descendants of a document node have to be block nodes.
|
||||
|
||||
In some places, you'll see mention of "fragments", which are also `Document` objects, just that aren't attached to the main `State`. For example, when cutting-and-pasting a selection of content, that content will be referred to as a document "fragment".
|
||||
|
||||
|
Reference in New Issue
Block a user