(returnFiber, current, element, expirationTime)
| 8894 | } |
| 8895 | |
| 8896 | function updateElement(returnFiber, current, element, expirationTime) { |
| 8897 | if (current !== null && current.type === element.type) { |
| 8898 | // Move based on index |
| 8899 | var existing = useFiber(current, element.props, expirationTime); |
| 8900 | existing.ref = coerceRef(returnFiber, current, element); |
| 8901 | existing['return'] = returnFiber; |
| 8902 | { |
| 8903 | existing._debugSource = element._source; |
| 8904 | existing._debugOwner = element._owner; |
| 8905 | } |
| 8906 | return existing; |
| 8907 | } else { |
| 8908 | // Insert |
| 8909 | var created = createFiberFromElement(element, returnFiber.mode, expirationTime); |
| 8910 | created.ref = coerceRef(returnFiber, current, element); |
| 8911 | created['return'] = returnFiber; |
| 8912 | return created; |
| 8913 | } |
| 8914 | } |
| 8915 | |
| 8916 | function updatePortal(returnFiber, current, portal, expirationTime) { |
| 8917 | if (current === null || current.tag !== HostPortal || current.stateNode.containerInfo !== portal.containerInfo || current.stateNode.implementation !== portal.implementation) { |
no test coverage detected