1.0.1 • Published 7 years ago

pen-js v1.0.1

Weekly downloads
2
License
ISC
Repository
github
Last release
7 years ago

pen-js

PenJs is a basic, lightweight js drawing board that is easy to customize and improve, hope you enjoy :)'

Installation

You can download de source code from github, or use npm to download the package. npm: npm install pen-js --save

After importing PenJs you just have to initialize the plugin:

var pen = new PenJs('#my-container-id');

I will be adding functionalities to this as the library evolve, for now we have this :) .toDataURL(outputType) outputType optional, can be 'jpg' or 'png', default is 'png'. Will return a base64 representation of the drawing. .redraw() Will repaint the canvas. .clear() Will clear the canvas.