UNPKG

polyfill-service

Version:
6 lines (4 loc) 137 B
Math.tanh = function tanh(x) { var y; return x === Infinity ? 1 : x === -Infinity ? -1 : (y = Math.exp(2 * x), (y - 1) / (y + 1)); };