@samitouri / QOS-React / commits / df4a09d9b8

Updated flow-bin from 91 -> 93 and removed unnecessary fixmes

Brian Vaughn committed Feb 21, 2019 at 09:15 UTC df4a09d9b8b34294503b5542bd4434cc6dbfe951
13 files changed +8 -25
package.json
+1 -1
@@ -73,7 +73,7 @@
73 "fbjs": "0.5.1",
74 "fbjs-scripts": "0.7.0",
75 "firefox-profile": "^1.0.2",
76 - "flow-bin": "^0.91.0",
76 + "flow-bin": "^0.93.0",
77 "fs-extra": "^3.0.1",
78 "gh-pages": "^1.0.0",
79 "immutable": "3.7.6",
shells/dev/app/ElementTypes/index.js
-1
@@ -15,7 +15,6 @@ import React, {
15 } from 'react';
16
17 const Context = createContext('abc');
18 -// $FlowFixMe Flow doesn't support this property yet.
18 Context.displayName = 'ExampleContext';
19
20 class ClassComponent extends Component<any> {
shells/dev/app/InspectableElements/Contexts.js
-9
@@ -52,31 +52,22 @@ class LegacyContextConsumer extends Component<any> {
52 }
53
54 const ModernContext = createContext();
55 -// $FlowFixMe Flow does not yet know about Context.displayName
55 ModernContext.displayName = 'ModernContext';
56 const ArrayContext = createContext(contextData.array);
58 -// $FlowFixMe Flow does not yet know about Context.displayName
57 ArrayContext.displayName = 'ArrayContext';
58 const BoolContext = createContext(contextData.bool);
61 -// $FlowFixMe Flow does not yet know about Context.displayName
59 BoolContext.displayName = 'BoolContext';
60 const FuncContext = createContext(contextData.func);
64 -// $FlowFixMe Flow does not yet know about Context.displayName
61 FuncContext.displayName = 'FuncContext';
62 const NumberContext = createContext(contextData.number);
67 -// $FlowFixMe Flow does not yet know about Context.displayName
63 NumberContext.displayName = 'NumberContext';
64 const StringContext = createContext(contextData.string);
70 -// $FlowFixMe Flow does not yet know about Context.displayName
65 StringContext.displayName = 'StringContext';
66 const SymbolContext = createContext(contextData.symbol);
73 -// $FlowFixMe Flow does not yet know about Context.displayName
67 SymbolContext.displayName = 'SymbolContext';
68 const NullContext = createContext(null);
76 -// $FlowFixMe Flow does not yet know about Context.displayName
69 NullContext.displayName = 'NullContext';
70 const UndefinedContext = createContext(undefined);
79 -// $FlowFixMe Flow does not yet know about Context.displayName
71 UndefinedContext.displayName = 'UndefinedContext';
72
73 class ModernContextType extends Component<any> {
shells/dev/app/InspectableElements/CustomHooks.js
-1
@@ -5,7 +5,6 @@ import React, {
5 Fragment,
6 memo,
7 useCallback,
8 - // $FlowFixMe Flow doesn't yet know about this hook
8 useDebugValue,
9 useEffect,
10 useState,
src/backend/renderer.js
-1
@@ -272,7 +272,6 @@ export function attach(
272 const symbolOrNumber =
273 typeof type === 'object' && type !== null ? type.$$typeof : type;
274
275 - // $FlowFixMe facebook/flow/issues/2362
275 return typeof symbolOrNumber === 'symbol'
276 ? symbolOrNumber.toString()
277 : symbolOrNumber;
src/devtools/views/InspectedElementTree.js
+1 -1
@@ -129,7 +129,7 @@ export function KeyValue({
129 </div>
130 );
131 } else {
132 - // $FlowFixMe
132 + // $FlowFixMe "Missing type annotation for U" whatever that means
133 children = Object.entries(value).map(([name, value]) => (
134 <KeyValue
135 key={name}
src/devtools/views/OwnersStack.js
-1
@@ -13,7 +13,6 @@ import styles from './OwnersStack.css';
13 export default function OwnerStack() {
14 const { ownerStack, resetOwnerStack } = useContext(TreeContext);
15
16 - // $FlowFixMe "Missing type annotation for U" whatever that means
16 const elements = ownerStack.map((id, index) => (
17 <ElementView key={id} id={id} index={index} />
18 ));
src/devtools/views/SearchInput.js
+1 -1
@@ -20,7 +20,7 @@ export default function SearchInput(props: Props) {
20 setSearchText,
21 } = useContext(TreeContext);
22
23 - const inputRef = useRef();
23 + const inputRef = useRef<HTMLInputElement | null>(null);
24
25 const handleTextChange = useCallback(
26 ({ currentTarget }) => setSearchText(currentTarget.value),
src/devtools/views/SettingsContext.js
-1
@@ -21,7 +21,6 @@ type Context = {|
21 |};
22
23 const SettingsContext = createContext<Context>(((null: any): Context));
24 -// $FlowFixMe displayName is a valid attribute of React$ConsearchText
24 SettingsContext.displayName = 'SettingsContext';
25
26 type Props = {|
src/devtools/views/Tree.js
+1 -1
@@ -30,7 +30,7 @@ export default function Tree(props: Props) {
30 selectNextElementInTree,
31 selectPreviousElementInTree,
32 } = useContext(TreeContext);
33 - const listRef = useRef<FixedSizeList<any>>();
33 + const listRef = useRef<FixedSizeList<any> | null>(null);
34
35 const { lineHeight } = useContext(SettingsContext);
36
src/devtools/views/TreeContext.js
-1
@@ -59,7 +59,6 @@ type Context = {|
59 |};
60
61 const TreeContext = createContext<Context>(((null: any): Context));
62 -// $FlowFixMe displayName is a valid attribute of React$ConsearchText
62 TreeContext.displayName = 'TreeContext';
63
64 type State = {|
src/devtools/views/context.js
-2
@@ -7,9 +7,7 @@ import type { Bridge } from '../../types';
7 import Store from '../store';
8
9 export const BridgeContext = createContext<Bridge>(((null: any): Bridge));
10 -// $FlowFixMe displayName is a valid attribute of React$Context
10 BridgeContext.displayName = 'BridgeContext';
11
12 export const StoreContext = createContext<Store>(((null: any): Store));
14 -// $FlowFixMe displayName is a valid attribute of React$Context
13 StoreContext.displayName = 'StoreContext';
yarn.lock
+4 -4
@@ -4586,10 +4586,10 @@ flatstr@^1.0.4:
4586 version "1.0.5"
4587 resolved "https://registry.yarnpkg.com/flatstr/-/flatstr-1.0.5.tgz#5b451b08cbd48e2eac54a2bbe0bf46165aa14be3"
4588
4589 -flow-bin@^0.91.0:
4590 - version "0.91.0"
4591 - resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.91.0.tgz#f5c89729f74b2ccbd47df6fbfadbdcc89cc1e478"
4592 - integrity sha512-j+L+xNiUYnZZ27MjVI0y2c9474ZHOvdSQq0Tjwh56mEA7tfxYqp5Dcb6aZSwvs3tGMTjCrZow9aUlZf3OoRyDQ==
4589 +flow-bin@^0.93.0:
4590 + version "0.93.0"
4591 + resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.93.0.tgz#9192a08d88db2a8da0ff55e42420f44539791430"
4592 + integrity sha512-p8yq4ocOlpyJgOEBEj0v0GzCP25c9WP0ilFQ8hXSbrTR7RPKuR+Whr+OitlVyp8ocdX0j1MrIwQ8x28dacy1pg==
4593
4594 flush-write-stream@^1.0.0:
4595 version "1.0.3"