(ref, create, deps)
| 15515 | } |
| 15516 | |
| 15517 | function mountImperativeHandle(ref, create, deps) { |
| 15518 | { |
| 15519 | if (typeof create !== 'function') { |
| 15520 | error('Expected useImperativeHandle() second argument to be a function ' + 'that creates a handle. Instead received: %s.', create !== null ? typeof create : 'null'); |
| 15521 | } |
| 15522 | } // TODO: If deps are provided, should we skip comparing the ref itself? |
| 15523 | |
| 15524 | |
| 15525 | var effectDeps = deps !== null && deps !== undefined ? deps.concat([ref]) : null; |
| 15526 | return mountEffectImpl(Update, Layout, imperativeHandleEffect.bind(null, create, ref), effectDeps); |
| 15527 | } |
| 15528 | |
| 15529 | function updateImperativeHandle(ref, create, deps) { |
| 15530 | { |
no test coverage detected