forked from facebook/react
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[flow] annotate accumulate and accumulateInto
Summary: Trying to start adding flow types to files in React. I needed to add a script to package.json in order to run flow, flow-bin is already a dependency. I had to rewrite the implementation a bit. Flow doesn't recognize ``` var currentIsArray = Array.isArray(current); if (currentIsArray) { // not refined } ``` but the following does work ``` if (Array.isArray(current)) { // refined } ``` Test Plan: npm run-script flow npm run-script test accumulate Reviewers: @zpao @spicyj
- Loading branch information
Showing
4 changed files
with
33 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters