hook-use-document-visibility (npm): This hook checks if the browser tab the user is in is active  and how many times the page has been visited by the user
Keywords: react|hook|document|visibility