And that’s why canvas libraries exist. Fabric.js, Pixi.js, Canvas.js, Kinetic.js – they all came about to make working with the canvas element a bit easier.
So why does the world need another canvas library? Why did I bother to write Scrawl-canvas when there’s already a lot of other libraries out there already?
I needed to write Scrawl-canvas because I have a vision for the <canvas> element that those other libraries don’t seem to share. I want the <canvas> element to be an integral, first-class member of the HTML family – not an add-on (like Flash), but rather something that can be added to any website … and add value to that website. I wanted a system where boxes and circles on the canvas can interact on an equal footing with all the other DOM elements on the webpage. Where canvas entitys and DOM elements shared a common language for positioning, sizing and styling; for animations and tweens.
A mad, bad, gloriously technicolor world where coding canvases became as much fun as coding the rest of the website.
Does Scrawl-canvas realise this vision? Almost! It won’t be long before that vision is realised. In the meantime, feel free to check out my demos over on CodePen, and visit GitHub to get (or fork) your own copy of the library – github.com/KaliedaRik/Scrawl-canvas.