Make Comment Default Blogger For AMP
Resize File icon by Icons8

Make folder ‘resize-gif’

$ mkdir resize-gif

Change directory

$ cd resize-gif

Folder Structure

resize-gif
├─ app.js
└─ test.gif

app.js

const gifResize = require('@gumlet/gif-resize')
const fs = require("fs")

const bufferFile = fs.readFileSync("test.gif")
gifResize({
    width: 100
})(bufferFile).then(buffer => {
    var stream = fs.createWriteStream("result.gif")
    stream.write(buffer)
    stream.end()
    console.log('Success')
})

NPM initial

$ npm init -y

Install package www.npmjs.com/package/@gumlet/gif-resize

$ npm i @gumlet/gif-resize

Testing

$ node app.js