Nanobots Producing Megastructures

    js-svg-piano

    1.0.0 • Public • Published

    js-svg-piano

    Very small module for drawing a piano using js and svg

    The point in using svg is that it is easy to scale multiple octaves to fit exact in a single div container

    Install

    npm install --save js-svg-piano
    

    Usage

    var p = require('js-svg-piano');
    var elemID = 'piano-container';
     
    var p = new piano(elemID, {
            octaves: 2,
            octaveBegin: 3
    });
     
    p.createPiano();

    You can see index.html which includes the bundle built from test.js

    You can see the example here:

    https://diversen.github.io/js-svg-piano/

    Related

    Build and watch example

    ./watch
    

    License

    MIT © Dennis Iversen

    Install

    npm i js-svg-piano

    DownloadsWeekly Downloads

    2

    Version

    1.0.0

    License

    MIT

    Last publish

    Collaborators

    • diversen