How to change the orientation of a canvas in fabric.js?

Viewed 470

I am loading a background image and then adding different texts/shapes on the canvas.

I am trying to implement a functionality for the user to change the orientation of the whole canvas in fabric js, from portrait to landscape and vice-versa. I am not restricted on the exact functionality, but I don't have too many ideas on how to do it.

Changing the transform property from CSS, then changing the angle of all objects in canvas, doesn't seem good. Transform property messes up some functionalities of fabric js (selection, moving, scaling, etc...)

Any other ideas on how to do it?

0 Answers
Related