I found an example that allow me to rotate text in JS 3.x - Edit Tools
Is there a similar function for JS 4.x? I am able to rotate polygon, but not text.