polyfills.Math.sign.raw.js Maven / Gradle / Ivy
The newest version!
// Math.sign
Math.sign = function sign(x) {
return !(x = Number(x)) ? x : x > 0 ? 1 : -1;
};
// Math.sign
Math.sign = function sign(x) {
return !(x = Number(x)) ? x : x > 0 ? 1 : -1;
};