sus-2-image
TypeScript icon, indicating that this package has built-in type declarations

2.3.2 • Public • Published

sus-2-image

SeaUrchinScore to Image for node

npm sus:v2.17.0

Description

*.sus to Image.

Installation

$ yarn add sus-2-image

How to use

const Sus2Image = require('sus-2-image')
const fs = require('fs')
 
const sus = fs.readFileSync('example.sus','utf8')
 
Sus2Image.getSVG(sus).then(image => {
  fs.writeFileSync(`score.svg` , image)
})
 
Sus2Image.getPNG(sus).then(image => {
  fs.writeFileSync(`score.png` , image)
})
 
Sus2Image.getPNGs(sus).then(images => {
  images.forEach((image, index) => {
    fs.writeFileSync(`score_${index}.png` , image)
  })
})

Readme

Keywords

none

Package Sidebar

Install

npm i sus-2-image

Weekly Downloads

32

Version

2.3.2

License

MIT

Unpacked Size

67.3 kB

Total Files

10

Last publish

Collaborators

  • mizucoffee