Fabric.js : A Powerful JavaScript Library to work with Canvas

By Mahesh Chand Dec 19, 2012
Fabric.js : A Powerful JavaScript Library to work with Canvas
  • 0
  • 0
  • 2856
JavaScript is becoming more and more popular these days. Now, with Fabric.js, we can even draw simple and complex shapes using JavaScript. 

From the website:

Fabric.js is a powerful and simple Javascript canvas library that can be used to draw shapes on a canvas. 

Using Fabric.js, you can create and populate objects on canvas; objects like simple geometrical shapes — rectangles, circles, ellipses, polygons, or more complex shapes consisting of hundreds or thousands of simple paths.

You can then scale, move, and rotate these objects with the mouse; modify their properties — color, transparency, z-index, etc. You can also manipulate these objects altogether — grouping them with a simple mouse selection.

You can add text on canvas and dynamically manipulate its size, alignment, fontfamily and other properties. You can apply filters to images, making them grayscale or removing background. You can serialize the entire canvas into a JSON string — saving it locally or on a server — then completely restore it at any time. You can also export canvas data back into SVG at any time.

Learn more about Fabric.js here >

Mahesh Chand

Mahesh Chand is founder of C# Corner. C# Corner founded in 1999 is a FREE member contributions based open platform for developers to solve problems, learn new technology and hang out.  Mahesh has been awar... Read more



Hire Mobile & Web Developer on demand. 100% satisfaction. Try for 1 week or Money Back. Local and remote developers available all over USA.