rbt

reacket-boots-template

A base skeleton template for react and webpack without task runners

Showing:

Popularity

Downloads/wk

0

Maintenance

No Maintenance Data Available

Package

Dependencies

7

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Deprecated!
this package is not maintained and should not be used anymore

Readme

Installation

  1. 配置后端环境(略)

  2. 安装 Git:yum install git

  3. 在服务器上安装 node: https://nodejs.org/dist/v4.2.1/

  4. 从仓库中拉取项目 git clone git@git.corp.qihoo.net:g-platform-dev/private-cloud-fe.git 并切换到 develop 分支

    $ cd private-cloud-fe
    $ git checkout develop
    
  5. 进入项目页添加 nginx 配置文件并添加文件到 .gitignore 中:

    $ cd src/nginx
    $ cp lizheming.cloud.cn.conf yourname.conf  # 修改 yourname 为你的文件名
    $ vi yourname.conf  # 修改 server_name 和 root 为对应的地址,其中 root 需要指定到 provate-cloud-fe/dist 文件夹
    
  6. 修改 private-cloud-fe/src/common/request/index.js 中的第 4 行地址为配置好的后端地址并将此文件添加到 .gitignore

  7. 安装所需要的依赖并编译:

    $ cd private-cloud-fe
    $ npm install --registry=https://registry.npm.taobao.org
    $ npm run dist
    
  8. 将 nginx 配置文件软链到 NGINX 配置文件夹中:

    ln -s /home/lizheming/private-cloud-fe/dist/nginx/yourname.conf /usr/local/nginx/conf/yourname.conf
    
  9. 重启 NGINX 服务

Installation Tips

如果是 Windows 环境安装 node-sass 之前需要安装 VS Express

npm install --registry=https://registry.npm.taobao.org --verbose

编译

npm run build
npm run buildmin
npm run dist

启动调试

npm start
npm startdist

后者和前者的区别是startdist会进行压缩并单独拷贝到dist目录,和线上环境最接近

用到的组件

jquery
bootstrap
react
react-router
react-boostrap

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Alternatives

No alternatives found

Tutorials

No tutorials found
Add a tutorial