installed "flow" in package.json and incorporated into github workflow #65
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This static analysis type checker tool "Flow" was not installed in the first checkpoint and has just been added as a tool we want to integrate.
In order to install flow, run
npm install --save-dev flow-bin
This will install the package flow into your project. You can see the changes inside the package.json file on line 164 where you will see"flow-bin": "^0.250.0"
Inside the package.json file, add"flow": "flow"'
to line 18 after the coveralls script.The above steps would allow you to use the flow package locally.
Then to run this tool, run the command
npm run flow init
the first time you run this tool. This will generate the file .flowconfig which has been added to the files changed.Then, run the command
npm run flow
which will actually check your code against the tool. Look for the "No errors!" line in the output.We can see that there aren't any errors or warnings that the Flow tool is flagging.
Lastly, to integrate the tool into the workflow on Github, copy the code or the changes you made from package.json into install/package.json. This is because the Github workflow uses the packages from install/package.json. Then, go to .github/workflows/test.yaml and add the installation line and the run flow line.