这是一个根据 Create React App 改造过来的cli;
开始已开发环境启动项目
打开 http://localhost:3000 在浏览器中展示.
页面当你有改动文件时回自动刷新;
当代码有问题时你也可以看到一些错误信息
Launches the test runner in the interactive watch mode.
打包你的app到 build
文件夹
把打包好的项目上传到ftp上;所以你需要去修改你的ftp配置;在config/userConf.js
里
module.exports= {
ftp:{
host: "***.my3w.com",//服务器地址
user: "**",//用户名
password: "**"//密码
},
remote:"/htdocs/**" // 服务器目录
}
以下是Create React App 原有的内容;自己看一下把;对项目没有太大影响
You can learn more in the Create React App documentation.
To learn React, check out the React documentation.
This section has moved here: https://facebook.github.io/create-react-app/docs/code-splitting
This section has moved here: https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size
This section has moved here: https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app
This section has moved here: https://facebook.github.io/create-react-app/docs/advanced-configuration
This section has moved here: https://facebook.github.io/create-react-app/docs/deployment
This section has moved here: https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify