(fn, a)
| 13931 | // TODO: Batching should be implemented at the renderer level, not within |
| 13932 | // the reconciler. |
| 13933 | function flushSync(fn, a) { |
| 13934 | !!isRendering ? invariant(false, 'flushSync was called from inside a lifecycle method. It cannot be called when React is already rendering.') : void 0; |
| 13935 | var previousIsBatchingUpdates = isBatchingUpdates; |
| 13936 | isBatchingUpdates = true; |
| 13937 | try { |
| 13938 | return syncUpdates(fn, a); |
| 13939 | } finally { |
| 13940 | isBatchingUpdates = previousIsBatchingUpdates; |
| 13941 | performSyncWork(); |
| 13942 | } |
| 13943 | } |
| 13944 | |
| 13945 | function interactiveUpdates(fn, a, b) { |
| 13946 | if (isBatchingInteractiveUpdates) { |
nothing calls this directly
no test coverage detected