Page Contents
Home > @loopback/rest > RoutingTable > registerController
RoutingTable.registerController() method
Register a controller as the route
Signature:
registerController<T>(spec: ControllerSpec, controllerCtor: ControllerClass<T>, controllerFactory?: ControllerFactory<T>): void;
Parameters
| Parameter | Type | Description |
|---|---|---|
| spec | ControllerSpec | |
| controllerCtor | ControllerClass<T> | |
| controllerFactory | ControllerFactory<T> |
Returns:
void