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

pizza-guy

v1.4.2

Published

If you already have a big list of urls of files that you want to download but you don't know how, this is your module.

Downloads

76

Readme

pizza-guy

Travis Codecov NPM Downloads Total Commitizen Friendly Semantic Released Join the chat at https://gitter.im/pizza-guy/Lobby

If you already have a big list of urls of files that you want to download but you don't know how, this is your module.

The idea is to support really big lists of files that would be insane to download simultaneously since Node would break for this kind of cases. Hope others to support this cause. ✌🏻

How to use

Require / Import

import pizzaGuy from 'pizza-guy';
// or
var pizzaGuy = require('pizza-guy');

Prepare your data

const images = [
  'http://some.domain.com/file0.jpg',
  'https://some.domain.com/file1.gif',
  'https://some.domain.com/file2.png'
];

or, if you want to alter the filenames on download...

const image = [
  { url: 'http://some.domain.com/file0.jpg', name: 'goat.jpg' },
  { url: 'http://some.domain.com/file1.gif', name: 'cat.gif' },
  { url: 'https://some.domain.com/file2.png', name: 'hawk.png' }
];

Execute

pizzaGuy
  // Pass an array of strings containing urls or an array of objects with urls and names...
  .deliver(images)
  // Absolute or relative path to save these files...
  .onAddress('./some-path')
  // Will trigger per file...
  .onSuccess((info) => {
    console.log(`${info.fileName} succeed!`);
  })
  // Will trigger per file that failed..
  .onError((info) => {
    console.log(`${info.fileName} failed`);
  })
  // Initialize the utility!
  .start();

Want a demo?

You can try out this module without any hassle. Just run npm run demo and you're all set. You can also run npm run demo:large if you want to try it with more files.

Demo files are located in demo/index.js and downloaded images will be located in demo/downloaded-images

How to contribute

This project is opened to everyone to contribute. If you want to, please read our GitHub issues and look for any that suits better to you. Also read about Commitizen Friendly and Semantic Released since the build is relying on these to test and publish automatically on NPM.

Please don't forget to run npm run demo before submitting any change just to double check that everything is working like a charm. We are expecting to have this as part of the testing suite but we are still working on it.

Please use npm run commit instead of git commit -m "your message" since we're using semantic release + commitizen and we aim to have things as tidy as possible.

Issues / bugs

We are working once on a while in this small library. Please report an issue here and we'll take a look as soon as we can.