$ npm install -g @jimizai/foxx-cli
$ foxx init <project-name>
// main.ts
import { boostrap } from '@jimizai/core';
import { KoaFoxxDriver } from '@jimizai/driver-koa';
import './app/home.controller';
boostrap({
Driver: KoaFoxxDriver,
srcDirs: [],
});
// app/home.controller.ts
import { Get, Controller } from '@jimizai/decorators';
@Controller()
export class HomeController {
@Get()
home() {
return 'hello foxx';
}
}
- simple - A simple example to quick start use foxx