0
点赞
收藏
分享

微信扫一扫

通过 npm 使用 React

前提已经安装好了node

 


$ npm install -g cnpm --registry=https://registry.npm.taobao.org $ npm config set registry https://registry.npm.taobao.org

 

使用 create-react-app 快速构建 React 开发环境

 

 

执行以下命令创建项目:


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

在浏览器中打开 ​​http://localhost:3000/​​ ,结果如下图所示:

通过 npm 使用 React_开发环境


举报

相关推荐

0 条评论