* Sets the React-specific ID of the given node. * * @param {DOMElement} node The DOM node whose ID will be set. * @param {string} id The value of the ID attribute.
(node, id)
| 10734 | * @param {string} id The value of the ID attribute. |
| 10735 | */ |
| 10736 | function setID(node, id) { |
| 10737 | var oldID = internalGetID(node); |
| 10738 | if (oldID !== id) { |
| 10739 | delete nodeCache[oldID]; |
| 10740 | } |
| 10741 | node.setAttribute(ATTR_NAME, id); |
| 10742 | nodeCache[id] = node; |
| 10743 | } |
| 10744 | |
| 10745 | /** |
| 10746 | * Finds the node with the supplied React-generated DOM ID. |
nothing calls this directly
no test coverage detected