npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

generator-stack-node

v1.0.6

Published

Stack generator boilerplate of API for NodeJs

Downloads

39

Readme

Generator Stack NodeJs

Build Status Coverage Status Dependencies Status DevDependencies Status

NPM

Stack boilerplate personal from API NodeJs.

Overview

Generator using Yeoman.

The generator creates an express API model compiling the code with Babel, comes with integration with PostgreSql database, token authentication with Passport using JWT and possibility of reporting errors by Sentry. It has a documentation generator using apiDoc. Contains lint tests using esLint, TDD tests using Mocha and code coverage using nyc.

Generated Project Dependencies

Dependencies Status DevDependencies Status

Installation

Commands to install the tools to run the generator.

# tools
$ npm install npm -g
$ npm install yo -g

# generator
$ npm install -g generator-stack-node

Usage

Commands to run the generator.

$ yo stack-node <options>

Options

The options that are not informed will be requested by the generator when initiating project.

  -h,     --help          # Print the generator's options and usage
          --skip-cache    # Do not remember prompt answers                                  Default: false
          --skip-install  # Do not automatically install dependencies                       Default: false
  -n,     --name          # What is the project name?
  -d,     --description   # What is a short description for this project?
  -a,     --author        # Who is the author of this project?
  -e,     --email         # What is the email of the author of this project?
  -h,     --homepage      # What is the project homepage?
  -dbu,   --dbuser        # What is the connection user with postgres?
  -dbp,   --dbpassword    # What is the access password for connection to postgres?
  -dbh,   --dbhost        # What is the host of the database?
  -dbp,   --dbport        # What is the database port?
  -s,     --sentry        # If you have report sentry DNS to monitor errors in production.

Directory

|-- name-project                                 # Project name
    |-- .editorconfig                            # Maintain consistent coding styles
    |-- .gitignore                               # Contains files to be ignored when pushing to git
    |-- gulpfile.js                              # Link all splittered gulp tasks
    |-- package.json                             # Holds various metadata relevant to the project
    |-- README.md                                # Contains the details of the generated project
    |-- src                                      # The source code of the application
    |   |-- index.js                             # Application main file
    |   |-- api                                  # Main project folder
    |       |-- app.js                           # Module that starts the server
    |       |-- config                           # General settings folder
    |       |   |-- config.js                    # File that loads the settings according to the environment
    |       |   |-- auth                         # Authentication settings folder
    |       |   |   |-- passport.js              # Authentication configuration module using passport
    |       |   |-- db                           # Database module folder
    |       |   |   |-- database.js              # PostgreSql database module
    |       |   |-- env                          # Project settings folder
    |       |   |   |-- development.env          # Development environment settings
    |       |   |   |-- production.env           # Production environment settings
    |       |   |   |-- test.env                 # Test environment settings
    |       |   |-- validator                    # Express validation folder
    |       |       |-- sanitizers.js            # Sanitizers of express
    |       |-- models                           # Templates folder
    |       |   |-- user.model.js                # User model manipulation of data with the database
    |       |-- routes                           # Application routes
    |           |-- routes.js                    # Standard and custom route file
    |           |-- auth                         # Authentication routes folder
    |           |   |-- auth.js                  # Token request route
    |           |-- exposed                      # Folder of other routes
    |           |   |-- users.js                 # User registration routes
    |           |-- responses                    # Responses definitions folder
    |               |-- handlers.js              # Standard responses to requests
    |-- test                                     # The source code of the tests
        |-- mocha.opts                           # Mocha options and parameters
        |-- data                                 # Fictitious data folder
        |   |-- user.json                        # User registration data
        |-- integration                          # Integration testing folder
        |   |-- index.spec.js                    # Main integration testing file
        |   |-- modules                          # Integration test modules
        |       |-- authentication.spec.js       # Authentication test file
        |       |-- routes.spec.js               # Standard route test file
        |       |-- user.spec.js                 # User test file
        |-- loader                               # Folder files that are required by the tests
        |   |-- globals.js                       # Loads modules and global settings
        |-- unitary                              # Unitary testing folder
            |-- index.spec.js                    # Main unitary testing file
            |-- modules                          # Unitary test modules
                |-- authentication.spec.js       # Authentication test file
                |-- database.spec.js             # Database connection test file
                |-- user.spec.js                 # User test file

Generator Development

Procedures in the development of the generator.

Run

Run project in development mode.

# start submodules
$ git submodule init

# populating the submodule
$ git submodule update

# link package npm
$ npm link

# create a tarball from a package
$ npm pack

# run generator
$ yo stack-node <options>

Tests

Run test to ensure generator functionality.

$ npm test

Authors

| Guilherme Alves| |:---------------------:| | Guilherme Alves |

License

License MIT