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

npm-auto-snapshot

v0.5.3

Published

Bump your snapshot with the epoch. Keep snapshots out of production.

Downloads

5,849

Readme

npm-auto-snapshot

Build Status Coverage Status

This package was inspired by npm-snapshot but automates versioning and adds several features, including a version check for production builds.

It's very easy to use.

Unless your build is contained entirely within your js-package I recommend installing globally for use across multiple projects.

CLI

There are two cli commands available. Call them in a directory with the relevant package.json file, or pass the path to the package.json file.

>> npm_update_snapshot

This command updates the current version of a package.json file to x.y.z-SNAPSHOT.

Intended use

Run before build publishes development package version to npm.

requirements

The package.json's .version property must be of the format /d+.d+.d+-SNAPSHOT/

arguments

When called within the same directory as the package.json file you wish to modify, this command needs no arguments. Alternatively, you may pass a relative or absolute path to the package.json or its directory.

>> npm_check_no_snapshots

This command scans a package.json file for a version or dependencies ending in /-SNAPSHOT(.\d+)?$/ If any are found it throws an exception.

Intended use -

Run at the start of a build intended to produce production artifacts.

requirements

There should be no instances of -SNAPSHOT in any versions within the package.json.

Within another package

If used within another package, the following functions are exposed. They throw exceptions if they encounter errors.

snapshotUpdate:

NpmSnapshot = require('npm-auto-snapshot');

NpmSnapshot.snapshotUpdate('/path/to/the/package.json', console.log);

noSnapshotScan

NpmSnapshot = require('npm-auto-snapshot');

NpmSnapshot.noSnapshotScan('/path/to/the/package.json', console.log);