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 🙏

© 2024 – Pkg Stats / Ryan Hefner

@maximdevoir/node-module-boilerplate

v0.20.1

Published

A node module boilerplate

Downloads

1

Readme

Node Module Boilerplate

A modern boilerplate for developing and building Node modules.

license Known
Vulnerabilities

Installation

Begin by cloning the repository

git clone https://github.com/MaximDevoir/node-module-boilerplate.git my-module

cd my-module

yarn install

You can now yarn run start and being editing the source at src/index.js.

Tests can be added to the tests directory. Tests execute by yarn run test when they follow the naming format *.spec.js.

Features

  • Webpack V4
  • Babel setup to ES9, exporting to UMD.
  • ESLint for linting
  • Mocha and Chai for testing
  • NYC and Istanbul for code coverage, with Coveralls for online coverage
  • GitHub Actions for branch pushes and conditional publish to NPM, with separate Action for Pull Requests. See .github/main.workflow for instructions on setting up.
  • Probot Stale, see .github/stale.yml for installation instruction.

GitHub Actions

The workflow file is located at .github/main.workflow. To begin using actions, you must add the following secrets to your GitHub's repository:

  • SNYK_TOKEN for integration with Snyk's dependency vulnerability detection service. Go to your Snyk Account Settings to retrieve your API token.
  • NPM_AUTH_TOKEN for automatic public publishing to NPM. Visit https://www.npmjs.com/settings/USERNAME/tokens to generate a new token with read and publish access level.
  • COVERALLS_REPO_TOKEN for code coverage from Coveralls. Get the repo token, after syncing Coveralls with your repository, from https://coveralls.io/repos

Probot Stale

Configuration for probot-stale - https://github.com/probot/stale

Scripts

Building

Running yarn run build will build the module in production mode. Your module is now ready to be published.

Coverage

yarn run coverage generates a coverage report. You can view the output in the coverage/ directory.

Linting

yarn run lint will lint all applicable files in your project. You can run yarn run lint:fix to fix issues that can be fixed automatically.

Starting

yarn start or yarn run start will build the application in development mode and watch for changes in your src/ directory. Run yarn run start:once to build once and exit.

Testing

yarn run test will execute your tests in tests/*.spec.js once. You may also use yarn run test:watch to continue running tests as changes are detected.

License

MIT