yTakkar / Handy-Image-Processor

A handy Image Processor for NodeJS. πŸ“·πŸ“·πŸ“·

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Handy-Image-Processor

A handy, simple & useful Image Processor for NodeJS with very simple API.

Requirements

  1. gm

Install

First install.

# with npm
npm install handy-image-processor

# or with Yarn
yarn add handy-image-processor

Usage

// Import
const Processor = require('handy-image-processor')

// For processing
Processor.ProcessImage(options:Object):Promise
options = {
    srcFile,    // Image source      [eg. './src/image.gif']
    width,      // width you want    [eg. 100]
    height,     // height you want   [eg. 100]
    destFile:   // Image destination [eg. './dest/'+ new Date().getTime() +'.png']
}

// For deleting all the files of any given folder
Processor.DeleteFolder(folder:String):Promise

About

A handy Image Processor for NodeJS. πŸ“·πŸ“·πŸ“·


Languages

Language:JavaScript 100.0%