README
download ugoira and merge up to webp.
Installation
- download libwebp (^1.0.0) from https://github.com/webmproject/libwebp
- unzip bin to ./lib/libwebp_(osx|linux|win[64|32]/)
- install this package on package manager.
import Ugoira from 'node-ugoira';
// it's a great art! look at here -> https://www.pixiv.net/member_illust.php?mode=medium&illust_id=70727676
const ugoira = new Ugoira(70727676);
// you need to get refresh token first
// from pixiv api package likes 'pixiv-api-client', 'pixiv-app-api' things...
const out1 = await ugoiraw.initUgoira(refreshToken);
console.log(out1);
/*
{
extractedPath: string,
downloadedFile: string
}
*/
const out2 = await (await ugoiraw.toWebp()).toAnimated();
console.log(out2);
/*
{
outFilePath: string,
status: string (10[0|1]\n@Message...@)
}
*/