omi/packages/omi-cli
dntzhang 5045c356db update cli 2018-11-07 09:05:44 +08:00
..
bin ready for typescript template 2018-10-20 21:57:32 +08:00
lib add isSafeToCreateProjectIn function to verify which is valid folder to create a project 2018-10-30 02:21:00 +11:00
template update cli 2018-11-07 09:05:44 +08:00
.eslintrc eslintrc (#93) 2018-10-22 12:39:56 +03:00
.gitignore standart code styling 2018-10-21 22:56:05 +03:00
.npmignore omi-cli 2018-10-19 08:04:39 +08:00
README.md update readme 2018-10-26 22:09:17 +08:00
package.json update version 2018-11-05 16:29:03 +08:00
yarn.lock omi-cli 2018-10-19 08:04:39 +08:00

README.md

CLI

$ 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
$ npm start                      # develop
$ npm run build                  # release

Directory description:

├─ config
├─ public
├─ scripts
├─ src
│  ├─ assets
│  ├─ elements    //Store all custom elements
│  ├─ store       //Store all this store of pages
│  ├─ admin.js    //Entry js of compilerwill build to admin.html
│  └─ index.js    //Entry js of compilerwill build to index.html

TypeScript Template(omi-cli v3.0.3+):

$ 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
$ npm start                         # develop
$ npm run build                     # release

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

License

This content is released under the MIT License.