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

@wandyezj/standard-node

v0.0.6

Published

Standard node operations in nice wrappers.

Downloads

21

Readme

standard-node

Standard operations in nice wrappers.

  • string
  • list
  • file
  • directory

Import

import * as standard from "@wandyezj/standard-node";

About

Zero external dependencies.

Node Types and TypeScript are the only dependencies.

Standard Parameter Names

  • path
  • string
  • list
  • directory - full directory path
  • file - full file path

Philosophy

deterministic

Every run of the program with the same inputs should produce the same result.

In some cases external dependencies may have some variation (for example order of files in a directory), care should be taken to sanitize the input where possible so that it appears deterministic.

determinism makes testing and reproducing issues substantially easier.

complete

An action should never be in a partial state.

The action should complete fully or throw an error.

Ideally actions would be part of a transaction where all actions would succeed or nothing would happen.

An error indicates that the action could not complete and the program may now be in an unknown state.

In some cases complete is not possible due to the way that dependency APIs such as the file system are structured.

intuitive

Short descriptive memorable names are preferred over longer names.

The same words should be used for the same action, patterns should be applicable as far as possible.

Thoughts

Does it make sense to have the library to eliminate hierarchy in favor of individual importable functions? - may ease maintenance - may ease lookup of functions since there is one place to look - can introduce the concept of function groups later