Function controller

Generates a routes controller for the application container to mount.

const myController = controller((app) => {
const router = app.getRouter();
const ctrl = new MyController();
return router.get('...', ctrl.doSomething()).post('...', ctrl.doSomethingElse());
});

// ...
container.mount('/charo', myController);