From b0bc715980c99fa5430f2eb083911f462f22252a Mon Sep 17 00:00:00 2001 From: Marek Suscak Date: Fri, 30 Sep 2016 17:06:22 +0200 Subject: [PATCH 1/2] Add syntax highlighting configuration guide. --- packages/react-scripts/template/README.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/react-scripts/template/README.md b/packages/react-scripts/template/README.md index f44647ca3a8..1930d7a928a 100644 --- a/packages/react-scripts/template/README.md +++ b/packages/react-scripts/template/README.md @@ -13,6 +13,7 @@ You can find the most recent version of this guide [here](https://github.com/fac - [npm test](#npm-test) - [npm run build](#npm-run-build) - [npm run eject](#npm-run-eject) +- [Syntax Highlighting in the Editor](#syntax-highlighting-in-the-editor) - [Displaying Lint Output in the Editor](#displaying-lint-output-in-the-editor) - [Installing a Dependency](#installing-a-dependency) - [Importing a Component](#importing-a-component) @@ -144,6 +145,10 @@ Instead, it will copy all the configuration files and the transitive dependencie You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it. +## Syntax Highlighting in the Editor + +To configure the syntax highlighting in your favorite text editor, head to the [Babel's docs](https://babeljs.io/) and follow the instructions. Some of the most popular editors are covered. + ## Displaying Lint Output in the Editor >Note: this feature is available with `react-scripts@0.2.0` and higher. @@ -362,7 +367,7 @@ Inside `index.html`, you can use it like this: Only files inside the `public` folder will be accessible by `%PUBLIC_URL%` prefix. If you need to use a file from `src` or `node_modules`, you’ll have to copy it there to explicitly specify your intention to make this file a part of the build. -When you run `npm run build`, Create React App will substitute `%PUBLIC_URL%` with a correct absolute path so your project works even if you use client-side routing or host it at a non-root URL. +When you run `npm run build`, Create React App will substitute `%PUBLIC_URL%` with a correct absolute path so your project works even if you use client-side routing or host it at a non-root URL. In JavaScript code, you can use `process.env.PUBLIC_URL` for similar purposes: From 1812e8c3674c0f24c81107a76dfe0fc33037bdff Mon Sep 17 00:00:00 2001 From: Marek Suscak Date: Tue, 6 Dec 2016 15:13:11 +0100 Subject: [PATCH 2/2] Update link. --- 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 7d05219f436..bdb88df6023 100644 --- a/packages/react-scripts/template/README.md +++ b/packages/react-scripts/template/README.md @@ -159,7 +159,7 @@ You don’t have to ever use `eject`. The curated feature set is suitable for sm ## Syntax Highlighting in the Editor -To configure the syntax highlighting in your favorite text editor, head to the [Babel's docs](https://babeljs.io/) and follow the instructions. Some of the most popular editors are covered. +To configure the syntax highlighting in your favorite text editor, head to the [Babel's docs](https://babeljs.io/docs/editors) and follow the instructions. Some of the most popular editors are covered. ## Displaying Lint Output in the Editor