Fastify Boom support - HTTP-friendly error objects
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.editorconfig
.eslintignore
.eslintrc.json
.gitignore
.prettierignore
.prettierrc
.travis.yml
LICENSE
README.md
example.js
index.js
package-lock.json
package.json
test.js

README.md

fastify-boom

Fastify Boom support - HTTP-friendly error objects

Current Version Build Status

Install

npm i fastify-boom

Usage

const fastify = require('fastify')()
const Boom = require('boom')

fastify.register(require('fastify-boom'))

fastify.get('/', async function (req, reply) {
  throw new Boom('Opppps!')
})

fastify.listen(3000, err => {
  if (err) {
    fastify.log.error(err)
  }
})

Credits

  • boom HTTP-friendly error objects