From 970e15fc892ae9a4e1df262c8ab55f59a209687c Mon Sep 17 00:00:00 2001 From: SBrown52 Date: Fri, 10 Feb 2017 16:01:13 +0000 Subject: [PATCH 1/4] Update flow configuration documentation The documentation was missing creating the .flowconfig file --- packages/react-scripts/template/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/react-scripts/template/README.md b/packages/react-scripts/template/README.md index c85e544720b..597872a30ed 100644 --- a/packages/react-scripts/template/README.md +++ b/packages/react-scripts/template/README.md @@ -501,7 +501,8 @@ To add Flow to a Create React App project, follow these steps: 1. Run `npm install --save-dev flow-bin`. 2. Add `"flow": "flow"` to the `scripts` section of your `package.json`. -3. Add `// @flow` to any files you want to type check (for example, to `src/App.js`). +3. Create `.flowconfig` in your project root directory +4. Add `// @flow` to any files you want to type check (for example, to `src/App.js`). Now you can run `npm run flow` to check the files for type errors. You can optionally use an IDE like [Nuclide](https://nuclide.io/docs/languages/flow/) for a better integrated experience. From 06968b3a3b2b0f5c0f82b99cd4a5542512ca4e92 Mon Sep 17 00:00:00 2001 From: SBrown52 Date: Thu, 23 Feb 2017 22:17:34 +0000 Subject: [PATCH 2/4] Update flow configuration documentation Adding in suggested changes --- packages/react-scripts/template/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react-scripts/template/README.md b/packages/react-scripts/template/README.md index 597872a30ed..ce05d9cd4e1 100644 --- a/packages/react-scripts/template/README.md +++ b/packages/react-scripts/template/README.md @@ -501,7 +501,7 @@ To add Flow to a Create React App project, follow these steps: 1. Run `npm install --save-dev flow-bin`. 2. Add `"flow": "flow"` to the `scripts` section of your `package.json`. -3. Create `.flowconfig` in your project root directory +3. Create `.flowconfig` in your project root directory. You can either create this file manually or run `npm run flow -- init`. You can find more flow configuration options [here](https://flowtype.org/docs/advanced-configuration.html) 4. Add `// @flow` to any files you want to type check (for example, to `src/App.js`). Now you can run `npm run flow` to check the files for type errors. From 159f6a557f60ed89c39fd775aaa5ff38319af8d2 Mon Sep 17 00:00:00 2001 From: Dan Abramov Date: Fri, 24 Feb 2017 16:20:13 +0000 Subject: [PATCH 3/4] Wording --- packages/react-scripts/template/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react-scripts/template/README.md b/packages/react-scripts/template/README.md index ce05d9cd4e1..1611b746ac6 100644 --- a/packages/react-scripts/template/README.md +++ b/packages/react-scripts/template/README.md @@ -501,7 +501,7 @@ To add Flow to a Create React App project, follow these steps: 1. Run `npm install --save-dev flow-bin`. 2. Add `"flow": "flow"` to the `scripts` section of your `package.json`. -3. Create `.flowconfig` in your project root directory. You can either create this file manually or run `npm run flow -- init`. You can find more flow configuration options [here](https://flowtype.org/docs/advanced-configuration.html) +3. Create `.flowconfig` in your project root directory. You can either create this file manually or run `npm run flow -- init`. You can leave it empty or [configure it](https://flowtype.org/docs/advanced-configuration.html) if you need to. 4. Add `// @flow` to any files you want to type check (for example, to `src/App.js`). Now you can run `npm run flow` to check the files for type errors. From d71fce8bb3d270805b0c053eadfcdcf5ecce13a3 Mon Sep 17 00:00:00 2001 From: Dan Abramov Date: Fri, 24 Feb 2017 16:21:42 +0000 Subject: [PATCH 4/4] Wording --- packages/react-scripts/template/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react-scripts/template/README.md b/packages/react-scripts/template/README.md index 1611b746ac6..166ca5664f4 100644 --- a/packages/react-scripts/template/README.md +++ b/packages/react-scripts/template/README.md @@ -501,7 +501,7 @@ To add Flow to a Create React App project, follow these steps: 1. Run `npm install --save-dev flow-bin`. 2. Add `"flow": "flow"` to the `scripts` section of your `package.json`. -3. Create `.flowconfig` in your project root directory. You can either create this file manually or run `npm run flow -- init`. You can leave it empty or [configure it](https://flowtype.org/docs/advanced-configuration.html) if you need to. +3. Run `npm run flow -- init` to create a [`.flowconfig` file](https://flowtype.org/docs/advanced-configuration.html) in the root directory. 4. Add `// @flow` to any files you want to type check (for example, to `src/App.js`). Now you can run `npm run flow` to check the files for type errors.