5 lines
122 B
JavaScript
5 lines
122 B
JavaScript
export default function(a, b) {
|
|
return a = +a, b = +b, function(t) {
|
|
return Math.round(a * (1 - t) + b * t);
|
|
};
|
|
}
|