@voom/wire

0.1.2 • Public • Published

@voom/wire

Absolute paths for Hapi.

This plugin allows you to import modules using absolute paths.

Installation

npm install @voom/wire

Usage

const Hapi = require('@hapi/hapi')
const Wire = require('@voom/wire')

const Config = Wire.config('server')  // :root:/config/server.js
const Logger = Wire.plugins('logger') // :root:/plugins/logger.js

async function start () {
  const server = Hapi.Server(Config)

  await server.register(Logger)

  await server.start()
}

start()

Package Sidebar

Install

npm i @voom/wire

Weekly Downloads

0

Version

0.1.2

License

MIT

Unpacked Size

4.15 kB

Total Files

5

Last publish

Collaborators

  • spridev