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

pkgpig

v0.3.3

Published

Manage semantic versioning in a monorepo context.

Downloads

2

Readme

🐷 pkgpig

WIP: This is a refactor of some other CLI I wrote. Hopefully there are no bugs. But if so please report it on GitHub. Thank you for your patience.

Latest Version Badge Test Status Badge Publish Status Badge

Manage semantic versioning in a monorepo context.

This tool is opinionated. Mostly, the opinion is that historically people are secretly bad at semantic versioning (often a secret to even them). They may claim otherwise, but that's only because they haven't critically broken anyone's stuff yet.

SemVer can't stop problems like side-effects, hidden dependencies, React.context mismatches, build-origin closures, and more. That's why as a policy:

pkgpig implements the rule that if an internal package bumps a major version, then all packages dependent on it get major bumped too (and their dependents, and so on).

This policy is an extension of SemVar. It prevents the footguns mentioned. Admittedly, it can be annoying at times - but it is far less of a headache to manage for your consumers than mal-versioned packages. Unless you really know what you are doing, just let the tool do its job (even then, you should probably trust it anyway).

Install

It's a global CLI. Node 14+ (but 12 might work too - not tested yet).

npm i -g pkgpig

CLI

sync

Wizard to walk you through updating your monorepo's internal dependencies. It will allow you to:

  • Prepare new version releases, including the ramifications of releasing new packages may have on the others
  • View out of sync @your-org packages
  • Update @your-org packages to use the most current versions of each other
pkgpig sync

CLI shortcuts to the sync options coming in a later version

graph

Output the inverse dependency graph for the current monorepo. (What @your-org packages are dependent on a given package)

pkgpig graph [packageNames...]

Will output something of the order

@your-org/form is depended on by: 
  as a dependency:       @your-org/login-dialog  @your-org/subscribe-form
  as a devDependency:    @your-org/ui

@your-org/ui is depended on by: 
  as a peerDependency:   @your-org/form  @your-org/login-dialog  @your-org/subscribe-form
...

Contributing

Run the following to test / dev locally:

npm install
npm link

Authorship

Created, with love, by @KyleWestCS