Rotate positions in 2D space. Has many overloads and you can curry it if you want.
const rotate = let newPosition; // width, height, angle, x, ynewPosition = // returns [ x, y ] // ..., { x, y }newPosition = // returns { x, y } // ..., [ x, y ]newPosition = // returns [ x, y ] // You can call it if a list with the types above if you want. newPosition = // returns [ [ x, y ], ... ] // Currying is fine too. curried = newPosition = // All overloads work while curried.