@turistforeningen/express-error

Custom error handler for Express.js

Usage no npm install needed!

<script type="module">
  import turistforeningenExpressError from 'https://cdn.skypack.dev/@turistforeningen/express-error';
</script>

README

express-error

Build status NPM downloads NPM version Node version Dependency status

Return JSON error objects from your Express backed API.

Requiremets

  • Node.JS v4.0.0 or newer
  • io.js v1.0.0 or newer

Install

npm install @turistforenignen/express-error --save

Usage

This should be put at the end of your Express route configurations. See the examples directory for more detailed examples.

app.use(require('@turistforenigen/express-error'));

MIT License