How can you catch the window exit event?

  • 0
    When moving the cursor away from the entire window, you need to catch the event
    JavaScript Noah Kelley, Jun 14, 2019

  • 1 Answers
  • 0
    So?

    document.addEventListener('mouseleave',()=>{
    console.log('leave');
    })
    Anonymous

Your Answer
To place the code, please use CodePen or similar tool. Thanks you!