update readme

This commit is contained in:
dntzhang 2018-11-25 15:30:24 +08:00
parent 4ae4686087
commit 7859db0737
9 changed files with 38 additions and 38 deletions

View File

@ -281,13 +281,13 @@ const [count, setCount] = this.useData(0)
```bash
$ npm i omi-cli -g # install cli
$ omi init your_project_name # init project, you can also exec 'omi init' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init my-app # init project, you can also exec 'omi init' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```
> `npx omi-cli init your_project_name` 也支持(要求 npm v5.2.0+)
> `npx omi-cli init my-app` 也支持(要求 npm v5.2.0+)
目录说明:
@ -332,19 +332,19 @@ $ npm run build # release
使用 TypeScript 模板(omi-cli v3.0.5+):
```bash
$ omi init-ts your_project_name
$ omi init-ts my-app
```
使用 omi-router [单页应用模板](https://tencent.github.io/omi/packages/omi-router/examples/spa/build/) (omi-cli v3.0.10+):
```bash
$ omi init-spa your_project_name
$ omi init-spa my-app
```
小程序开发 Web 模板(omi-cli v3.0.13+):
```bash
$ omi init-mp your_project_name
$ omi init-mp my-app
```
Cli 自动创建的项目脚手架是基于单页的 create-react-app 改造成多页的,有配置方面的问题可以查看 [create-react-app 用户指南](https://facebook.github.io/create-react-app/docs/getting-started)。

View File

@ -280,8 +280,8 @@ const [count, setCount] = this.useData(0)
```bash
$ npm i omi-cli -g # install cli
$ omi init your_project_name # init project, you can also exec 'omi init' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init my-app # init project, you can also exec 'omi init' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```
@ -329,19 +329,19 @@ mac os 에서:
TypeScript Template(omi-cli v3.0.5+):
```bash
$ omi init-ts your_project_name
$ omi init-ts my-app
```
[SPA Template](https://tencent.github.io/omi/packages/omi-router/examples/spa/build/)(omi-cli v3.0.10+):
```bash
$ omi init-spa your_project_name
$ omi init-spa my-app
```
omi-mp (Omi Wechat Mini Program Module) Template(omi-cli v3.0.13+):
```bash
$ omi init-mp your_project_name
$ omi init-mp my-app
```
CLI 자동 프로젝트 생성 scaffolding 는 한 페이지의 create-react-app을 여러 페이지로 변환합니다. 설정(configuration) 이슈는 [create-react-app user guide](https://github.com/facebook/create-react-app/blob/master/packages/react-scripts/template/README.md) 을 봐주세요.

View File

@ -282,13 +282,13 @@ const [count, setCount] = this.useData(0)
```bash
$ npm i omi-cli -g # install cli
$ omi init your_project_name # init project, you can also exec 'omi init' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init my-app # init project, you can also exec 'omi init' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```
> `npx omi-cli init your_project_name` is also supported(npm v5.2.0+).
> `npx omi-cli init my-app` is also supported(npm v5.2.0+).
Directory description:
@ -333,19 +333,19 @@ In mac os:
TypeScript Template(omi-cli v3.0.5+):
```bash
$ omi init-ts your_project_name
$ omi init-ts my-app
```
[SPA Template](https://tencent.github.io/omi/packages/omi-router/examples/spa/build/)(omi-cli v3.0.10+):
```bash
$ omi init-spa your_project_name
$ omi init-spa my-app
```
omi-mp Template(omi-cli v3.0.13+):
```bash
$ omi init-mp your_project_name
$ omi init-mp my-app
```
CLI's auto-created project scaffolding is based on a single-page create-react-app to be converted into a multi-page one, with configuration issues to see [create-react-app user guide](https://facebook.github.io/create-react-app/docs/getting-started)

View File

@ -2,13 +2,13 @@
```bash
$ npm i omi-cli -g # install cli
$ omi init your_project_name # init project, you can also exec 'omi init' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init my-app # init project, you can also exec 'omi init' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```
> `npx omi-cli init your_project_name` is also supported(npm v5.2.0+).
> `npx omi-cli init my-app` is also supported(npm v5.2.0+).
Directory description:
@ -27,13 +27,13 @@ Directory description:
TypeScript Template(omi-cli v3.0.5+):
```bash
$ omi init-ts your_project_name
$ omi init-ts my-app
```
[SPA Template](https://tencent.github.io/omi/packages/omi-router/examples/spa/build/)(omi-cli v3.0.10+):
```bash
$ omi init-spa your_project_name
$ omi init-spa my-app
```
CLI's auto-created project scaffolding is based on a single-page create-react-app to be converted into a multi-page one, with configuration issues to see [create-react-app user guide](https://github.com/facebook/create-react-app/blob/master/packages/react-scripts/template/README.md)

View File

@ -6,8 +6,8 @@
```bash
$ npm i omi-cli -g
$ omi init-mp your_project_name
$ cd your_project_name
$ omi init-mp my-app
$ cd my-app
$ npm start
$ npm run build
```

View File

@ -25,8 +25,8 @@
```bash
$ npm i omi-cli -g
$ omi init-mp your_project_name
$ cd your_project_name
$ omi init-mp my-app
$ cd my-app
$ npm start
$ npm run build
```

View File

@ -46,8 +46,8 @@ Omi 4.0 发布至今,收到了大量的意见和建议以及真刀真枪的 PR
```bash
$ npm i omi-cli -g # install cli
$ omi init your_project_name # init project, you can also exec 'omi init' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init my-app # init project, you can also exec 'omi init' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```
@ -70,8 +70,8 @@ $ npm run build # release
```bash
$ npm i omi-cli -g # install cli
$ omi init-ts your_project_name # init project, you can also exec 'omi init-ts' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init-ts my-app # init project, you can also exec 'omi init-ts' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```

View File

@ -46,8 +46,8 @@ Omi가 Web Components 와 Shadow-DOM 하기 떄문에 React 와 Vue 처럼 기
```bash
$ npm i omi-cli -g # install cli
$ omi init your_project_name # init project, you can also exec 'omi init' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init my-app # init project, you can also exec 'omi init' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```
@ -70,8 +70,8 @@ TypeScript 템플릿 사용 (omi-cli v3.0.3+):
```bash
$ npm i omi-cli -g # install cli
$ omi init-ts your_project_name # init project, you can also exec 'omi init-ts' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init-ts my-app # init project, you can also exec 'omi init-ts' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```

View File

@ -46,8 +46,8 @@ The tool is create by [F](https://github.com/f).
```bash
$ npm i omi-cli -g # install cli
$ omi init your_project_name # init project, you can also exec 'omi init' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init my-app # init project, you can also exec 'omi init' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```
@ -85,8 +85,8 @@ TypeScript Template(omi-cli v3.0.3+):
```bash
$ npm i omi-cli -g # install cli
$ omi init-ts your_project_name # init project, you can also exec 'omi init-ts' in an empty folder
$ cd your_project_name # please ignore this command if you executed 'omi init' in an empty folder
$ omi init-ts my-app # init project, you can also exec 'omi init-ts' in an empty folder
$ cd my-app # please ignore this command if you executed 'omi init' in an empty folder
$ npm start # develop
$ npm run build # release
```