@samitouri / QOS-React / commits / 2559030c34

Type ReactCurrentOwner (#7648)

Simpler than ReactOwner :)

Christopher Chedeau committed Sep 2, 2016 at 16:29 UTC 2559030c344a0e03e2ca03a231c7220671620170
2 files changed +5 -1
src/isomorphic/classic/element/ReactCurrentOwner.js
+4 -1
@@ -7,10 +7,13 @@
7 * of patent rights can be found in the PATENTS file in the same directory.
8 *
9 * @providesModule ReactCurrentOwner
10 + * @flow
11 */
12
13 'use strict';
14
15 +import type { ReactInstance } from 'ReactInstanceType';
16 +
17 /**
18 * Keeps track of the current owner.
19 *
@@ -23,7 +26,7 @@ var ReactCurrentOwner = {
26 * @internal
27 * @type {ReactComponent}
28 */
26 - current: null,
29 + current: (null: null | ReactInstance),
30
31 };
32
src/renderers/shared/stack/reconciler/ReactInstanceType.js
+1
@@ -34,4 +34,5 @@ export type ReactInstance = {
34 _mountImage: any,
35 // __DEV__
36 _debugID: DebugID,
37 + _warnedAboutRefsInRender: bool,
38 };