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

@ipp/trace

v1.0.4

Published

An image build orchestrator for the modern web

Downloads

5

Readme

Maintenance notice

This project is inactively maintained.

It works, I use it for my personal projects, but the documentation is incomplete and I don't have the time to actively continue developing the project.

I am around to answer any questions in the discussions tab. Use at your own risk!


npm   Code coverage   Node.js   Typescript   Make the web lighter

Image Processing Pipeline is a platform-agnostic modular collection of packages that aims to glue together various image libraries into and configurable automated pipeline.

Philosophy

Images make your websites pop, but they are also the largest asset that you serve to your client. Correctly optimising images provides a much better experience, by not wasting your visitors' bandwidth, battery and making the navigation of your website smoother.

At its highest level, Image Processing Pipeline is a command line tool that helps you automate your website's image build process in a non-destructive way, with speed and quality in mind. At a lower level, it is a modular set of functions that can be integrated into any existing backend service.

How it works

Image Processing Pipeline is built on top of three key concepts:

🌴 Pipeline

At the heart is a user-defined pipeline. A pipeline is a collection of pipes that can be assembled in any tree-like pattern, along with any additional options and an optional save key that will mark the pipe's output for export.

🔨 Pipe

Pipes are simple asynchronous functions that take a source image and output any number of formats. Pipes can apply any transformation to the source image, such as resizing, compressing or converting the image.

🔖 Metadata

Every image is accompanied by a metadata object, which is a collection of key-value pairs that describe the image. Pipes may modify an image's metadata object, which can later be used to customise the output filename or to create an image manifest file.

Features

  • Fast - Uses the amazing libvips image processing library
  • 🔥 Parallel - Scales to any amount of available cores
  • 💎 Lanczos3 - Quality-first image down-scaling algorithm
  • 📦 Works out of the box - Uses a sane default configuration
  • 🌍 Universal - Designed to works anywhere without lock-in
  • ✂️ Cross-platform - Tested on Windows, macOS and Linux
  • 😊 Friendly - an easy to use CLI experience

Getting started

Prerequisites

  • Node.js v10.8 or higher
  • npm

Installation

It is recommended to install IPP as a dependency of your project, this is just an example to quickly try it out

To give IPP a go on the command line, you will need to install the CLI package:

$ npm i -g @ipp/cli

This will add IPP to your path. Find a folder of images, and give it a go:

$ ipp -i folder/with/images -o output/folder

Configuration

In order to get the most out of IPP you need to set up a configuration file with all of your persistent values. This can be in your package.json, or in a file named .ipprc, .ipprc.yml or .ipprc.json.

Then all you need to do is run ipp from the terminal!

.ipprc.yml

# These will be the folders that will get processed,
# relative to the current working directory
input: folder/with/images
output: folder/with/images

# Remove this part to disable manifest generation
manifest:
  source:
    p: path
    x: "hash:8"
  format:
    w: width
    h: height
    f: format
    p: path
    x: "hash:8"

# Here is where you customise the pipeline
# This is what the default pipeline looks like
pipeline:
  - pipe: resize
    options:
      breakpoints:
        - name: sm
          resizeOptions:
            width: 480
        - name: md
          resizeOptions:
            width: 720
        - name: lg
          resizeOptions:
            width: 1920
        - name: xl
          resizeOptions:
            width: 3840
    save: "[name]-[breakpoint][ext]"
    then:
      - pipe: convert
        options:
          format: webp
        save: "[name]-[breakpoint][ext]"

Ready for more?

Check out the website for complete documentation on how to use Image Processing Pipeline.

Contributing

Contributions are what makes the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feat/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feat/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.