diff --git a/packages/react-dev-utils/package.json b/packages/react-dev-utils/package.json index 6e49955e45399427d6b8c513855643579bafaf89..dd59573dad6ef126d3bd83eaa465ec1a88af63de 100644 --- a/packages/react-dev-utils/package.json +++ b/packages/react-dev-utils/package.json @@ -1,6 +1,6 @@ { "name": "react-dev-utils", - "version": "5.0.0", + "version": "5.0.1", "description": "Webpack utilities used by Create React App", "repository": "facebook/create-react-app", "license": "MIT", diff --git a/packages/react-scripts/package.json b/packages/react-scripts/package.json index 889c14770ea153c732d75cf75e2bb8b545e17678..41bc05d93a90e3056af6780e950a7ec655a271c0 100644 --- a/packages/react-scripts/package.json +++ b/packages/react-scripts/package.json @@ -1,6 +1,6 @@ { "name": "react-scripts", - "version": "1.1.0", + "version": "1.1.4", "description": "Configuration and scripts for Create React App.", "repository": "facebook/create-react-app", "license": "MIT", diff --git a/packages/react-scripts/template/README.md b/packages/react-scripts/template/README.md index 437c9f273dba7466012cc31694a1694f1dddf7f7..e2ac1b38ac203bc396771436f28cc1a004e1b4cf 100644 --- a/packages/react-scripts/template/README.md +++ b/packages/react-scripts/template/README.md @@ -330,19 +330,23 @@ Now we can make sure every file is formatted correctly by adding a few lines to Add the following line to `scripts` section: -```diff - "scripts": { -+ "precommit": "lint-staged", - "start": "react-scripts start", - "build": "react-scripts build", -``` + ```diff + "scripts": { + "start": "react-scripts start", + "build": "react-scripts build", + ``` -Next we add a 'lint-staged' field to the `package.json`, for example: +Next we add 'lint-staged' and 'husky' fields to the `package.json`, for example: ```diff "dependencies": { // ... }, ++ "husky": { ++ "hooks": { ++ "pre-commit": "lint-staged" ++ } ++ }, + "lint-staged": { + "src/**/*.{js,jsx,json,css}": [ + "prettier --single-quote --write", @@ -352,7 +356,7 @@ Next we add a 'lint-staged' field to the `package.json`, for example: "scripts": { ``` -Now, whenever you make a commit, Prettier will format the changed files automatically. You can also run `./node_modules/.bin/prettier --single-quote --write "src/**/*.{js,jsx}"` to format your entire project for the first time. +Now, whenever you make a commit, Prettier will format the changed files automatically. You can also run `./node_modules/.bin/prettier --single-quote --write "src/**/*.{js,jsx,json,css}"` to format your entire project for the first time. Next you might want to integrate Prettier in your favorite editor. Read the section on [Editor Integration](https://prettier.io/docs/en/editors.html) on the Prettier GitHub page. @@ -2484,7 +2488,8 @@ With this setup Netlify will build and deploy when you push to git or open a pul 1. [Start a new netlify project](https://app.netlify.com/signup) 2. Pick your Git hosting service and select your repository -3. Click `Build your site` +3. Set `yarn build` as the build command and `build` as the publish directory +4. Click `Deploy site` **Support for client-side routing:**