@rehooks/document-visibility
Advanced tools
Comparing version 1.0.2 to 1.1.1
@@ -12,3 +12,3 @@ 'use strict'; | ||
function handleVisChange() { | ||
function handleVisibilityChange() { | ||
setDocumentVisibility(getVisibility()); | ||
@@ -18,5 +18,5 @@ } | ||
useEffect(() => { | ||
window.addEventListener('visibilitychange', handleVisChange); | ||
window.addEventListener('visibilitychange', handleVisibilityChange); | ||
return () => { | ||
window.removeEventListener('visibilitychange', handleVisChange); | ||
window.removeEventListener('visibilitychange', handleVisibilityChange); | ||
}; | ||
@@ -23,0 +23,0 @@ }, []); |
{ | ||
"name": "@rehooks/document-visibility", | ||
"version": "1.0.2", | ||
"version": "1.1.1", | ||
"description": "React hook for subscribing to document visibility", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
3496
0