Command line tools for creating Kite applications.
This tool initialize a folder with TypeScript configuration file tsconfig.json
and some basic files for developing Kite application.
npm install kite-tools
- Create a project folder, and change working directory to it:
mkdir kite-test
cd kite-test
- Run
npm init
to initialize node developing environment:
npm init
- Run Kite command line tools and follow the prompt to initialize Kite project:
kite init
For using everything with default, simply press enter
key to walk through the wizard.
- Compile and run
Template source files are placed into the project if everything ends normally in the above steps, so compile and run this application:
tsc
node dist/app.server.js
- Create Kite modules
create a controller as file "src/controllers/user/login.controller.ts":
kite -a user/login
create a service as file "src/services/user.service.ts":
kite -s user
create model as file "src/models/user.model.ts":
kite -m user
please note that entry point "dist/app.server.js" is the default setting, please replace it with your entry point file name if you specified other values.