MCPcopy Create free account
hub / github.com/Lobos/react-ui / getIDOfComposite

Function getIDOfComposite

docs/lib/react.js:9396–9407  ·  view source on GitHub ↗
(inst)

Source from the content-addressed store, hash-verified

9394var compositeIDMap;
9395var compositeIDCounter = 17000;
9396function getIDOfComposite(inst) {
9397 if (!compositeIDMap) {
9398 compositeIDMap = new WeakMap();
9399 }
9400 if (compositeIDMap.has(inst)) {
9401 return compositeIDMap.get(inst);
9402 } else {
9403 var id = compositeIDCounter++;
9404 compositeIDMap.set(inst, id);
9405 return id;
9406 }
9407}
9408
9409function getID(inst) {
9410 if (inst.hasOwnProperty('_rootNodeID')) {

Callers 2

getIDFunction · 0.85
react.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…