How to modify create-react-app to support multiple pages
May 28, 2018 pm 03:54 PMThis time I will show you how to modify create-react-app to support multi-page, and what are the precautions for modifying create-react-app to support multi-page. The following is a practical case. Let’s take a look.
Modify the dev process
Based on the project that has been generated through create-react-appyarn run eject
yarn add globby Used to view html files
1 2 3 4 5 |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
|
1 2 3 4 5 6 7 8 9 10 |
|
Modify product process
Modify config/1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
|
yarn add cpy)
1 2 3 4 5 6 7 8 9 10 |
|
yarn build
Added function
sass support (refer to the document of create-react-app, be careful not to directly copy the "start" in the document: "react-scripts start" , "build": "react-scripts build", because we have yarn eject before, so there are problems if you use it like this. You can try it yourself)1 2 3 4 5 6 7 8 9 10 11 12 |
|
1 2 3 |
|
1 |
|
How to build a webpack react development environment
The above is the detailed content of How to modify create-react-app to support multiple pages. For more information, please follow other related articles on the PHP Chinese website!

Hot Article

Hot tools Tags

Hot Article

Hot Article Tags

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

How to change the personal name in the group on DingTalk_How to modify the personal name in the group on DingTalk

How to Change User Folder Name: Win11 Tutorial

Can Douyin Blue V change its name? What are the steps to change the name of corporate Douyin Blue V account?

Win11 power mode modification location and method

Win10 sleep time modification tips revealed

PyCharm background color adjustment tips: Master it quickly!

Accelerate pip source and solve the problem of slow download speed

Guide to modifying win11 window corners to rounded corners
