1
0
mirror of https://github.com/ianstormtaylor/slate.git synced 2025-08-22 23:12:52 +02:00

Updated findDOMNode function (#892)

Newer implementations of findDOMNode take the node to find as the argument, not the key of the node
This commit is contained in:
Dylan Phelan
2017-06-21 17:31:12 -04:00
committed by Ian Storm Taylor
parent b6fc16593e
commit c7f14e1254

View File

@@ -18,9 +18,9 @@ Utility functions that ship with Slate that may be useful for certain use cases.
## Functions ## Functions
### `findDOMNode` ### `findDOMNode`
`findDOMNode(key: String) => DOMElement` `findDOMNode(node : Node) => DOMElement`
Allows you to find the DOM node for a Slate [`Node`](../models/node.md) by passing its `key` string. Modelled after React's built-in `findDOMNode` helper. Allows you to find the DOM node for a Slate [`Node`](../models/node.md). Modelled after React's built-in `findDOMNode` helper.
### `resetKeyGenerator` ### `resetKeyGenerator`
`resetkeygenerator() => Void` `resetkeygenerator() => Void`