How to use server-base - 1 common examples

To help you get started, we’ve selected a few server-base examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github fastify / benchmarks / benchmarks / server-base.js View on Github external
require('server-base')({
  '@setup' (ctx) {
    ctx.middlewareFunctions = []
  },
  '/': {
    get (req, res) {
      res.setHeader('content-type', 'application/json; charset=utf-8')
      res.json({ hello: 'world' })
    }
  }
}).start(3000)

server-base

server base

Apache-2.0
Latest version published 3 years ago

Package Health Score

42 / 100
Full package analysis

Popular server-base functions