mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-09-01 19:22:35 +02:00
Update docs to reflect Slate is an uncontrolled component (#4768)
* Updated documentation * Update docs/walkthroughs/01-installing-slate.md Co-authored-by: Dylan Schiemann <dylan@dojotoolkit.org> * fix: formatting errors Co-authored-by: Dylan Schiemann <dylan@dojotoolkit.org>
This commit is contained in:
committed by
GitHub
parent
1b0e7c6b92
commit
51e02de9de
@@ -110,7 +110,9 @@ const App = () => {
|
||||
}
|
||||
```
|
||||
|
||||
You can think of the `<Slate>` component as providing a "controlled" context to every component underneath it.
|
||||
You can think of the `<Slate>` component as providing a context to every component underneath it.
|
||||
|
||||
> As of v0.67 the Slate Provider's "value" prop is now only used as initial state for editor.children. If your code relies on replacing editor.children you should do so by replacing it directly instead of relying on the "value" prop to do this for you. See [Slate PR 4540](https://github.com/ianstormtaylor/slate/pull/4540) for a more in-depth discussion.
|
||||
|
||||
This is a slightly different mental model than things like `<input>` or `<textarea>`, because richtext documents are more complex. You'll often want to include toolbars, or live previews, or other complex components next to your editable content.
|
||||
|
||||
|
Reference in New Issue
Block a user