React development environment configuration

This article continues the above article configuration: npm install and configure the environment " https://www.cnblogs.com/hzb462606/p/11565275.html "

Using the create-react-app development environment to quickly build React

create-react-app from Facebook, you can quickly build React development environment we need to configure this command.

Project create-react-app is automatically created based on Webpack + ES6.

Execute the following command to create the project:

 cnpm install -g create-react-app
 create-react-app my-app
 cd my-app/
 npm start

possible problems:

Here Insert Picture Description

The reason: we manually modify the above default npm "node_global" position, you need to manually configure the environment variable to point to the latest "node_global"

First of all: right-click "My Computer" ------ "Properties" ------ "Advanced System Settings" ------ "Environment Variables":
when installing node.js specifies node_global the address of.
Written to the specified address node_global environment variable " path " can be.

Here Insert Picture Description

Restart cmd, perform create-react-app react-cli-app;

Here Insert Picture Description

Guess you like

Origin www.cnblogs.com/hzb462606/p/11565320.html