Home > @infiniteobjects/express-cloud-function > FunctionServer
Function server Class
Signature:
export declare class FunctionServer
Constructor | Modifiers | Description |
---|---|---|
(constructor)(config) | Constructs a new instance of the FunctionServer class |
Property | Modifiers | Type | Description |
---|---|---|---|
errorHandlers | ErrorRequestHandler[] | Error middleware to add to the request | |
log | readonly |
LoggerInstance | A Logger instance |
name | readonly |
string | Function name |
post | RequestHandler[] | Middleware to add to the request after the route handlers. | |
pre | RequestHandler[] | Middleware to add before the route handlers. A good example is loadUser |
|
routes | RouteConfig[] | The routes for this function | |
server | readonly |
Express | Express server instance |
staticPaths | string[] | Static paths to serve (MUST BE ABSOLUTE PATHS) | |
version | readonly |
string | Function version |
Method | Modifiers | Description |
---|---|---|
init() | ||
initSentry(dsn) | Initializes Sentry on the app | |
printConfig() |