You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

generator-hapi-composer

Package Overview
Dependencies
Maintainers
2
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

generator-hapi-composer

A hapi.js composer generator for Yeoman

latest
Source
npmnpm
Version
0.1.8
Version published
Weekly downloads
0
-100%
Maintainers
2
Weekly downloads
 
Created
Source

Hapi.js composer generator

NPM version Build Status Dependency Status Coverage Status

This generator creates a new hapi project with all the boilerplate you need to get started. The hapi-plugins selection in the prompt will be automatically added to the composer manifest.

Installation

Install the generator by running: npm install -g generator-hapi-composer

Usage

Make a new directory, and cd into it. Run the following command and follow the prompts.

yo hapi-composer

Note that this template will generate files in the current directory, so be sure to first change to a new directory if you don't want to overwrite existing files.

Hapi plugins

The generator provides the following optional selection of hapi-plugins by default:

You can customize the hapi-plugins prompt by editing the .yo-rc-global.json file which is located in your home directory. The file will be generated after the first run if it doesn't already exist. The default hapi-plugin configuration in .yo-rc-global.json looks like this:

{
  "generator-hapi-composer": {
  "hapiPlugins": [
        {
          "name": "lout",
          "description": "API documentation generator"
        },
        {
          "name": "hapi-auth-cookie",
          "description": "Cookie authentication plugin"
        },
        {
          "name": "bell",
          "description": "Third-party login plugin"
        },
        {
          "name": "hapi-auth-basic",
          "description": "Basic authentication plugin"
        },
        {
          "name": "tv",
          "description": "Interactive debug console"
        },
        {
          "name": "scooter",
          "description": "User-agent information plugin"
        },
        {
          "name": "poop",
          "description": "Plugin for handling uncaught exceptions"
        },
        {
          "name": "good",
          "description": "Server and process monitoring plugin"
        },
        {
          "name": "reptile",
          "description": "Plugin for creating a REPL"
        },
        {
          "name": "yar",
          "description": "Session plugin and cookie jar"
        },
        {
          "name": "crumb",
          "description": "CSRF crumb generation and validation"
        }
      ]
  }
}

npm modules

The generator provides the following optional selection of npm modules by default:

You can customize the npm-modules prompt by editing the .yo-rc-global.json file which is located in your home directory. The file will be generated after the first run if it doesn't already exist. The default npm-modules configuration in .yo-rc-global.json looks like this:

{
  "generator-hapi-composer": {
    "npmModules": [
      {
        "name": "joi",
        "description": "Object schema validation"
      },
      {
        "name": "boom",
        "description": "HTTP-friendly error objects"
      },
      {
        "name": "catbox",
        "description": "Multi-strategy object caching service"
      }
    ]
  }
}

Contributing

In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using gulp.

Support

Should you have any problems or wishes for improvements, feel free to open up an issue.

##Credits This generator is based on the generator-node-gulp.

##Contributors

License

Copyright (c) 2014 Kentaro Wakayama. Licensed under the MIT License.

Keywords

yeoman-generator

FAQs

Package last updated on 17 Oct 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts