A small, clean and neat 2d renderer lib. Kept in functional style.
const r = rect(w, h)
.translate(x, y)
.scaleX(sx)
.rotate(a);
const r = translate(x, y)(
scaleX(sx)(
rotate(a)(
rect(w, h)));
const r = compose(
rotate(a),
scaleX(sx),
translate(x,y),
rect(w, h)
);
const r2 = rcompose(
rect(w, h),
translate(x,y),
scaleX(sx),
rotate(a)
);