From 1dffd461f49346449a495cf8f7241a2930ef1e87 Mon Sep 17 00:00:00 2001 From: Nathan Bierema Date: Wed, 19 Sep 2018 03:04:57 -0400 Subject: [PATCH] Simplify methods --- types/react-reconciler/ReactFiberReconciler.d.ts | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/types/react-reconciler/ReactFiberReconciler.d.ts b/types/react-reconciler/ReactFiberReconciler.d.ts index 46f163038a..aa8ed61fe5 100644 --- a/types/react-reconciler/ReactFiberReconciler.d.ts +++ b/types/react-reconciler/ReactFiberReconciler.d.ts @@ -228,20 +228,14 @@ export interface Reconciler { flushRoot(root: OpaqueRoot, expirationTime: ExpirationTime): void; requestWork(root: OpaqueRoot, expirationTime: ExpirationTime): void; computeUniqueAsyncExpiration(): ExpirationTime; - batchedUpdates(fn: (a: A) => R, a: A): R; - unbatchedUpdates(fn: (a: A) => R, a: A): R; + batchedUpdates(fn: () => A): A; + unbatchedUpdates(fn: () => A): A; deferredUpdates(fn: () => A): A; - syncUpdates( - fn: (a: A, b: B, c: C0, d: D) => R, - a: A, - b: B, - c: C0, - d: D, - ): R; - interactiveUpdates(fn: (a: A, b: B) => R, a: A, b: B): R; + syncUpdates(fn: () => A): A; + interactiveUpdates(fn: () => A): A; flushInteractiveUpdates(): void; flushControlled(fn: () => any): void; - flushSync(fn: (a: A) => R, a: A): R; + flushSync(fn: () => A): A; // Used to extract the return value from the initial render. Legacy API. getPublicRootInstance(