woff2otf

WOFF to OTF converter for NodeJS

BSD-3-CLAUSE License

Downloads
190
Stars
3
Committers
4

woff2otf

Convert WOFF font files to OTF using NodeJS.

Installation

npm install woff2otf

Usage

CLI

woff2otf fontToConvert.woff outputFont.otf

WARNING: if the output file exists will be overwritten!

NodeJS

const fs = require('fs');
const woff2otf = require('woff2otf');

const woffFileBuffer = fs.readFileSync('path/to/file.woff');
const otfFileBuffer = woff2otf(woffFileBuffer);
fs.writeFileSync('path/to/file.otf', otfFileBuffer);

Thanks to

@hanikesn because this program is a port from Python of hanikesn/woff2otf