mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Remove unneeded declare (#7570)
It turns out that we don't need it, flow is smart enough to realize that the function is declared in the two branches :)
This commit is contained in:
committed by
GitHub
parent
f784a2d50a
commit
b977cf13c4
@@ -43,24 +43,6 @@ function isNative(fn) {
|
||||
}
|
||||
}
|
||||
|
||||
type Item = { // eslint-disable-line no-unused-vars
|
||||
element: ReactElement,
|
||||
parentID: DebugID,
|
||||
text: ?string,
|
||||
childIDs: Array<DebugID>,
|
||||
isMounted: bool,
|
||||
updateCount: number,
|
||||
};
|
||||
|
||||
declare function getItem(id: DebugID): ?Item;
|
||||
declare function removeItem(id: DebugID): void;
|
||||
declare function setItem(id: DebugID, item: Item): void;
|
||||
declare function getItemIDs(): Array<DebugID>;
|
||||
|
||||
declare function addRoot(id: DebugID): void;
|
||||
declare function removeRoot(id: DebugID): void;
|
||||
declare function getRootIDs(): Array<DebugID>;
|
||||
|
||||
var canUseCollections = (
|
||||
// Array.from
|
||||
typeof Array.from === 'function' &&
|
||||
|
||||
Reference in New Issue
Block a user