https://github.com/zlab/react-cli-service
without eject to custom webpack
https://github.com/zlab/react-cli-service
creact-react-app react react-cli react-scripts vue-cli
Last synced: about 1 month ago
JSON representation
without eject to custom webpack
- Host: GitHub
- URL: https://github.com/zlab/react-cli-service
- Owner: zlab
- License: mit
- Created: 2018-05-29T23:13:56.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2022-12-10T16:51:25.000Z (about 3 years ago)
- Last Synced: 2025-10-01T15:59:35.937Z (5 months ago)
- Topics: creact-react-app, react, react-cli, react-scripts, vue-cli
- Language: JavaScript
- Homepage:
- Size: 3.98 MB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 22
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# react cli service
比`create-react-app`更好用的`react cli`
## structs
参考[https://github.com/zlab/react-cli-demo](https://github.com/zlab/react-cli-demo)
## 已有项目
```
npm i react-cli-service -D
```
## package.json
```
"scripts": {
"serve": "react-cli-service serve",
"build": "react-cli-service build --report"
},
```
## 配置
新增`react.config.js`
## 入口
默认入口为`src/main.js`
# 新项目
## 下载模版
```
git clone https://github.com/zlab/react-cli-demo my-project
cd my-project
```
## install
`npm i` or `yarn`
## dev
`npm run serve` or `yarn serve`
## preview
[http://localhost:8080](http://localhost:8080)
## build
`npm run build` or `yarn build`
## 配置参考
[@vue/cli3](https://cli.vuejs.org/zh/config/)
[webpack-chain](https://github.com/neutrinojs/webpack-chain)