You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
250 B
12 lines
250 B
export default function(a, b) {
|
|
|
|
function compose(x, y) {
|
|
return x = a(x, y), b(x[0], x[1]);
|
|
}
|
|
|
|
if (a.invert && b.invert) compose.invert = function(x, y) {
|
|
return x = b.invert(x, y), x && a.invert(x[0], x[1]);
|
|
};
|
|
|
|
return compose;
|
|
}
|