Skip to content

Express App exposed

Compare
Choose a tag to compare
@Shudrum Shudrum released this 18 Mar 11:19
· 51 commits to master since this release
6afeb9e

It can be really useful to directly open routes from express instead of the gateway.

At Weekendesk, it is needed to expose some metrics.

This is why exposing the express app created by the gateway can be useful. You can achieve it now:

const gateway = nodegate();

gateway.expressApp.get('/metrics', (req, res) => {
  // Send the metrics
});