UNPKG

320 BJavaScriptView Raw
1import BaseApi from './Api';
2import { IndexApi } from './IndexApi';
3
4export class RootApi extends BaseApi {
5 getRoutes() {
6 return {
7 ...super.getRoutes(),
8 '/api': this.IndexApi || IndexApi,
9 '*': this.any.bind(this),
10 };
11 }
12 any(req, res) {
13 res.send('🦒');
14 }
15}
16
17export default RootApi;