In this article, we are going to see how to horizontally flip a canvas text in FabricJS. The text canvas means the text written is movable and can be stretched according to requirement. Further, the text itself cannot be edited like a textbox.
fabric.Text(text, flipX: Boolean);
Parameters: This function accepts two parameters as mentioned above and described below:
- text: It specifies the text to be written.
- options: It specifies the additional options to be applied and we are using the flipX option for this example.
Example: We can use FabricJS to horizontally flip a canvas text.