The Math tanh() static method returns the hyperbolic tangent of a number.

    
    console.log(Math.tanh(-1));
    // -0.7615941559557649

    console.log(Math.tanh(0));
    // 0

    console.log(Math.tanh(Infinity));
    // 1

    console.log(Math.tanh(1));
    // 0.7615941559557649