Skip to content

Commit 76bd132

Browse files
jayairgaearon
authored andcommitted
Docs: Added link to tutorial on code splitting (#2427)
* Adding link to tutorial on code splitting Link to tutorial on Code Splitting with React Router * Update README.md
1 parent 6e2898e commit 76bd132

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packages/react-scripts/template/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,10 @@ This will make `moduleA.js` and all its unique dependencies as a separate chunk
377377

378378
You can also use it with `async` / `await` syntax if you prefer it.
379379

380+
### With React Router
381+
382+
If you are using React Router check out [this tutorial](http://serverless-stack.com/chapters/code-splitting-in-create-react-app.html) on how to use code splitting with it. You can find the companion GitHub repository [here](https://github.com/AnomalyInnovations/serverless-stack-demo-client/tree/code-splitting-in-create-react-app).
383+
380384
## Adding a Stylesheet
381385

382386
This project setup uses [Webpack](https://webpack.js.org/) for handling all assets. Webpack offers a custom way of “extending” the concept of `import` beyond JavaScript. To express that a JavaScript file depends on a CSS file, you need to **import the CSS from the JavaScript file**:

0 commit comments

Comments
 (0)