A lightweight JavaScript library for drawing facilities on HTML5 canvas.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
dist
figs
.eslintrc.js
.gitignore
Gruntfile.js
LICENSE
README.md
jquery.sketchable.animate.js
jquery.sketchable.js
jquery.sketchable.memento.js
jquery.sketchable.svg.js
jsdoc.json
jsketch.js
jsketch.svg.js
package.json
sketchable.animate.js
sketchable.js
sketchable.memento.js
sketchable.svg.js Updated code doc Dec 17, 2017
sketchable.utils.js

README.md

jSketch

A lightweight JavaScript library for drawing facilities on an HTML5 canvas. Conveniently wrapped in a Sketchable class. Available also as a jQuery plugin.

Disclaimer: This library is mainly focused on free-form drawing, although it supports many of the native canvas methods. If you need a more complex solution try RaphäelJS or Fabric.js

Demos and documentation

g3 demo slm demo guessit demo mucaptcha demo smiley demo

TL;DR:

Vanilla JavaScript version

Add <script src="dist/sketchable.full.min.js"></script> to your page and just do:

var sketcher = new Sketchable('canvas');

jQuery version

Add <script src="dist/jquery.sketchable.full.min.js"></script> to your page and just do:

var $sketcher = $('canvas').sketchable();

That's it!

Want to know more? Go to demos and documentation.

License

This libray is released with the MIT license. The only requirement is that you keep my copyright notice intact when you repurpose, redistribute, or reuse this code.