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

buff

v1.0.0

Published

Buff your node repl or runtime with the best libraries and utilities.

Downloads

25

Readme

Buff

Quickly buff your Node environment with the best libraries and utilities when writing quick scripts or using the repl.

Inspired by Hoarders.

Usage

Install: npm install buff

Require in the repl or a file: require('buff')

Now you have access to all these goodies, predefined globally, no require() necessary:

Native Node Modules

All native node modules are pre-required for your convenience. Docs ex: fs.readFileSync('./file.txt')

General Utilities

lodash as _* or lodash - Utility library, successor to underscore.

  • The node repl takes control of _ for the last result so use lodash instead from the repl.

async - Flow control.

q - Promises Flow Control.

when - Promises.

open - Open the browser or file manager with the given URI. ex: open("http://www.google.com")

growl - Show Growl notification (or equivalent) with given message. You may need to sudo gem install terminal-notifier first. ex: growl("You have mail!")

moment - Date, time, and duration manipulation.

string as S - String manipulation. ex: S('-moz-something').camelize().s // 'mozSomething'

HTTP

request - HTTP request library. ex: request.get({url: "http://some.com/file.json", json:true}, function (err, res, body) { })

express - Easily create HTTP Servers.

ecstatic - Easily serve a directory over HTTP. ex: http.createServer(ecstatic('./')).listen(8080)

File System

mkdirp - mkdir -p, create all directories in given path. ex: mkdirp.sync("./some/new/folders")

mime - lookup mime types. ex: mime.lookup("/path/to/file.txt") // 'text/plain'

glob - Match files using patterns. ex: glob.sync("**/*.js")

wrench - Useful file system operations.

Formats

csv - Parse comma delimited strings. ex: csv().from.string('"1","2"\n"a","b"').to.array(function(data) { }) // data will be [[ '1', '2'], ['a', 'b']]

xml2json - Parse xml. ex: xml2json.toJson("<doc attr='val'><child>1</child><child>2</child></doc>") // {"doc":{"attr":"val","child":[1,2]}}

md5 - Md5 hash strings. ex: md5('message') // 78e731027d8fd50ed642340b7c9a63b3

CLI

cli-color as clc - Output colored text to your CLI. ex: clc.red('Text in red')

json-table as table - Print an array of objects as a table. ex: table([ {name: 'foo', age: 12}, {name: 'bar', age: 73} ])

eyes* - Pretty print Objects. ex: inspect({foo: "bar"})

  • inspect is an alias of eyes.inspect