When comparing Raphael vs Fabric.js, the Slant community recommends Raphael for most people. In the question“What are the best JavaScript drawing libraries?”Raphael is ranked 2nd while Fabric.js is ranked 8th. The most important reason people chose Raphael is:

Because Raphael supports rendering VML + SVG, it is one of the few drawing libraries that is backwards compatible with older browsers that do not support canvas.

Pros

Pro

Works with older browsers

Because Raphael supports rendering VML + SVG, it is one of the few drawing libraries that is backwards compatible with older browsers that do not support canvas.

Pro

Built in animations

Several built-in animations (such as ways of easing) are provided for you out of the box, but Raphael also allows cubic beziers for more complicated easing functions. Any drawing object property can be modified making it similar to css animations in jQuery.

Pro

Every object is interactive with events

Everything that is drawn in Raphael is an object which means it is easy to manipulate any part of the rendered image after it is processed. It uses an event handler system for user inputs which makes it easy to learn for JavaScript developers used to event based libraries.

This style of handling objects makes Raphael a good fit for rendering interactive diagrams and charts that can also interact with other parts of the page.

Pro

Easy creation of charts with extension

gRaphael is a Raphael extension to help you easily create graphs and charts.

Pro

Out of the box Node.js support

Fabric supports node.js, and has an npm package available for server side rendering with all the dependencies handled for you. This allows you to provide graceful degradation for image fallbacks to canvas or SVG content.

Pro

Outputs to canvas and SVG and JSON

When it comes to format compatibility, Fabric is the best, with the ability to output to Canvas, SVG, and JSON. SVG provides backwards compatibility for older browsers, and JSON allows you to store rendered output for later use.

Pro

Vector focused API

Drawing objects in fabric are vector focused, so everything is easily transformable. It makes it easy to create complex pathed shapes, add gradients, or filters. Although fabric is great for vector rendering, it also has image support as well.

Pro

Great interaction with SVG, excellent coding

If you are about to customize the library to your needs, this is the project of choice! Great programming work!

Pro

Good support for SVG multi-line text

Allows creating multi-line text that can even be interactively edited by user interaction.

Cons

Con

Complicated, confusing documentation

The documentation is often not clear and lacks practical examples.

Con

Can be difficult to get support

Online communities for Raphael are small and inactive compared to other drawing libraries, and many issues opened on github are never addressed.