{"_id":"in-viewport","_rev":"28-fde6a2439c01a85398e32362847fe72f","name":"in-viewport","description":"Get a callback when an element enters the viewport (body) or a custom viewport","dist-tags":{"latest":"3.6.0"},"versions":{"0.4.0":{"name":"in-viewport","version":"0.4.0","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"build/in-viewport.min.js","scripts":{"test":"grunt && zuul -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"grunt":"~0.4.2","grunt-closure-compiler":"0.0.21","grunt-contrib-jshint":"~0.7.2","zuul":"~1.0.9","merge":"~1.1.2","grunt-cli":"~0.1.11"},"bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport","_id":"in-viewport@0.4.0","dist":{"shasum":"79cd9b7264ec36aa2335a14c514ab22cd37b059a","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-0.4.0.tgz","integrity":"sha512-VWymBqhG4LrscnsjkHv9BLeg31qzsrjPN8eidj78evcusRujlo3KgtILU2K3GMfeMsCuirKcyCLP+Bgd73wlBw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDoCRlVGu97EboLRzIdLTzBXsUlnNuicbWK7B4AooT2BwIgWE/wQanUNs2T78Rkuz6xLTZJ1zmjSeq3p8LpuY+GEaY="}]},"_from":".","_npmVersion":"1.3.17","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}]},"0.4.1":{"name":"in-viewport","version":"0.4.1","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"build/in-viewport.min.js","scripts":{"test":"grunt jshint && zuul -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"grunt":"~0.4.5","grunt-closure-compiler":"0.0.21","grunt-contrib-jshint":"~0.10.0","zuul":"~1.6.5","merge":"~1.1.3","grunt-cli":"~0.1.13"},"gitHead":"16c00b960731ea5b93869465a62db9606e8be61e","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport","_id":"in-viewport@0.4.1","_shasum":"e5ab658819fa45943bf5af13bcc31b5f5295effa","_from":".","_npmVersion":"1.4.13","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"e5ab658819fa45943bf5af13bcc31b5f5295effa","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-0.4.1.tgz","integrity":"sha512-i70iZO6zbAwSrqm1E1sywH/a8mbRTmUD2RhZnKVQCFwPKqKl7ITNUe/FBSFwxzYEIzl/BMcDfk+AwtwTUK1T6A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDJZmAmXnzY+IvT9lMzF/BlMjZnxsyap5t1QZuWPkihEwIgQVJW3AUggXKXa+BpA4gRqYUhigntQkRD/m2roxvZA8A="}]}},"0.4.2":{"name":"in-viewport","version":"0.4.2","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"build/in-viewport.min.js","scripts":{"test":"grunt jshint && zuul -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"grunt":"^0.4.5","grunt-cli":"^0.1.13","grunt-closure-compiler":"^0.0.21","grunt-contrib-jshint":"^0.10.0","merge":"^1.2.0","zuul":"^1.10.2"},"gitHead":"a9238ce3c966f398b1df23eb730f01f1f7a2ad77","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport","_id":"in-viewport@0.4.2","_shasum":"ae700b56d0f68aae4c8c37df9f7abf4825fb4b23","_from":".","_npmVersion":"1.4.26","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"ae700b56d0f68aae4c8c37df9f7abf4825fb4b23","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-0.4.2.tgz","integrity":"sha512-RyJs1oQqPOawrZ1NotunkfUKqDUdubhRkhOtyAzXR2gBdbygM6gqW/iXbMEepyB4Xx8ngt9U4GtaUAhBeyeDAw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCAvF820AWvM6aeA7rupHkw58BRzgl1VKgQqE+FeKl5WQIgbO2izT7ddB+uNHTpS3XSCc5tJsl6eMkEUNjhE0+vDDY="}]}},"1.0.1":{"name":"in-viewport","version":"1.0.1","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & zuul --local 8080 -- test/*.js","test":"npm run build && zuul -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"^8.1.1","deumdify":"^1.0.4","merge":"^1.2.0","uglifyify":"^3.0.1","watchify":"^2.2.1","zuul":"^1.16.5"},"browserify":{"transform":[["uglifyify",{"mangle":true,"screw-ie8":true,"compress":{"sequences":true,"properties":true,"dead_code":true,"drop_debugger":true,"unsafe":true,"conditionals":true,"comparisons":true,"evaluate":true,"booleans":true,"loops":true,"unused":true,"hoist_funs":true,"if_return":true,"join_vars":true,"cascade":true,"drop_console":true}}]]},"gitHead":"1b81552ff70d05a0bac59003f3912b4a5e62aab9","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport","_id":"in-viewport@1.0.1","_shasum":"78a6dd57615fd7df507f79b97a93fa9e372d757d","_from":".","_npmVersion":"2.2.0","_nodeVersion":"0.10.35","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"78a6dd57615fd7df507f79b97a93fa9e372d757d","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-1.0.1.tgz","integrity":"sha512-/N/nEgpgf5isUUAyRjFPD1gglQ44WJaG60veMfX18XSyGuMjBo1CRP79WpeahdWIuRLhzZTww83KetVBT6zMlA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDDwhLLxc7NuZaEr38gBWukSaGpT5NiIreX7/Pvt1aKNAIgL29LXXuXYMrD9tNnYcxiLmkHzhfT5s8jMF8UzJK6VAE="}]}},"3.0.2":{"name":"in-viewport","version":"3.0.2","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"9.0.3","closurecompiler":"1.5.1","deumdify":"1.1.0","merge":"1.2.0","watchify":"2.4.0","zuul":"2.1.1","zuul-ngrok":"3.0.0"},"gitHead":"960213aac6e6e4b1bd7d56a7d0f1102f476a04e5","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport","_id":"in-viewport@3.0.2","_shasum":"2a4a5c44c8ce92826967d75eb5ff27a80fe55faa","_from":".","_npmVersion":"2.7.1","_nodeVersion":"0.10.36","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"2a4a5c44c8ce92826967d75eb5ff27a80fe55faa","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.0.2.tgz","integrity":"sha512-ZCZARoJqJuXuzZkbTrQZuQSVaVhAgXcbcFiVEpZFy5cBOpz3GORI98KhKJfNk1B1/3WXDXC/+KVXxXtUMlxamA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICCXZYXGu1p5uOLeC3E1a6QZwkZFJBELhc2GbixwDkAjAiEAjd1n+YVPWGhh6Ydw68vClMb1w6QZgNE9yEF1FVf/Pyw="}]}},"3.1.0":{"name":"in-viewport","version":"3.1.0","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"9.0.3","closurecompiler":"1.5.1","deumdify":"1.1.0","merge":"1.2.0","watchify":"2.4.0","zuul":"2.1.1","zuul-ngrok":"3.0.0"},"gitHead":"e1376e695ede9ff8c620e17e4eb6d057479fbd2a","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport#readme","_id":"in-viewport@3.1.0","_shasum":"9d68803f7cf84fe5b7d1aa1d288297d1adef4c26","_from":".","_npmVersion":"2.9.1","_nodeVersion":"0.12.3","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"9d68803f7cf84fe5b7d1aa1d288297d1adef4c26","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.1.0.tgz","integrity":"sha512-xAiC5Z1icDbZn6wXfsWgB3vmFNtxspIwEH5NP78GQYQ4W+/G+bn/2/QiRtBy71OEIGdgBsCV81qeA2ka6Bstdw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICmTlTw8Aq1zdQRmX9nuflwKPjmb+ePCTWBcDLjb9WC3AiEA1Ws4i5tBsiziBtuDlJ1Us7oOkVKl1A8+Knfd9Emu3XY="}]}},"3.2.0":{"name":"in-viewport","version":"3.2.0","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"9.0.3","closurecompiler":"1.5.1","deumdify":"1.1.0","merge":"1.2.0","watchify":"2.4.0","zuul":"2.1.1","zuul-ngrok":"3.0.0"},"gitHead":"10da0fa4f5008867194182c0a360a2c619465c79","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport#readme","_id":"in-viewport@3.2.0","_shasum":"5e34a1dd53d3b5cdbd7df3b10f1553d3ad1e4579","_from":".","_npmVersion":"2.9.1","_nodeVersion":"0.12.3","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"5e34a1dd53d3b5cdbd7df3b10f1553d3ad1e4579","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.2.0.tgz","integrity":"sha512-ViqWjbmE6YiT5xn3DvtRNJ0JSxHLA9eX56gw5rauefYaP8i3lRir23lx5w+Wc5bnBSa0gwXfMCu6fDLo8SJADQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAHNNAkS2lOvIYNv4y20XaZ/3nOhG+6mvK3XMpbZN8vnAiAVgH6pmIpBpJ9o/lpm1vV6rBbI9aS8Y+71wr1ZTCWjkQ=="}]}},"3.4.0":{"name":"in-viewport","version":"3.4.0","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"9.0.3","closurecompiler":"1.5.1","deumdify":"1.1.0","merge":"1.2.0","watchify":"2.4.0","zuul":"2.1.1","zuul-ngrok":"3.0.0"},"gitHead":"15232055c3f123425cd554d92c3197249c7c8522","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport#readme","_id":"in-viewport@3.4.0","_shasum":"350f888da530a5dd4b33ea4614210fe15a3b803d","_from":".","_npmVersion":"2.10.1","_nodeVersion":"0.12.4","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"350f888da530a5dd4b33ea4614210fe15a3b803d","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.4.0.tgz","integrity":"sha512-+wDqjl/oBG5OtIp0AhU5eZgZzL+eMad5xdgeHj5EOM+8l/UaiMAKSTYq9IoMogkztLt+gIhR2P4y9lp+WMN0ew==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCGHUs3KH9V8vXAxiQ/b6tk9HDfzjMDDtntftcXTc4+/wIgOJ+m5mTU114PwmBUtL+dtKKGPy3JuPj/pEDOrcLC+0k="}]}},"3.4.1":{"name":"in-viewport","version":"3.4.1","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"^12.0.1","closurecompiler":"^1.5.2","deumdify":"^1.2.2","merge":"1.2.0","watchify":"^3.6.1","zuul":"^3.7.3","zuul-ngrok":"3.0.0"},"gitHead":"9ca9f9172187b749dc5a4ae8f6f48f1f60fec147","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport#readme","_id":"in-viewport@3.4.1","_shasum":"ed3880d5e4a5ef40af6f89b4f4d6c4551f46dddb","_from":".","_npmVersion":"2.14.7","_nodeVersion":"4.2.2","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"tzi","email":"thomas@zilliox.me"},{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"ed3880d5e4a5ef40af6f89b4f4d6c4551f46dddb","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.4.1.tgz","integrity":"sha512-xOgzLVzshNq7MwCLzzOP+/PFsPlxg6CkGEC2pgr+sCUzKPZ/wgopl9ICNJSojLg6GBbeFMH7zbIOXGJ4131yIw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIA1U8dzuk9iKOvj9t8sterm1pHIgxduf2DXRQHBwoDNSAiEAg7fWC+GYDtf0TlI7TplWAeBiE4PMmUqeJgS+aO24rsw="}]}},"3.4.2":{"name":"in-viewport","version":"3.4.2","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"^12.0.1","closurecompiler":"^1.5.2","deumdify":"^1.2.2","merge":"1.2.0","watchify":"^3.6.1","zuul":"^3.11.0","zuul-ngrok":"^4.0.0"},"gitHead":"b65a2c8def64b46ad1abe32880c724fc1849330c","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport#readme","_id":"in-viewport@3.4.2","_shasum":"400b1c759b4b305ef19249429b7f202cdc6b7427","_from":".","_npmVersion":"3.10.8","_nodeVersion":"6.9.1","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"maintainers":[{"name":"tzi","email":"thomas@zilliox.me"},{"name":"vvo","email":"vincent.voyer@gmail.com"}],"dist":{"shasum":"400b1c759b4b305ef19249429b7f202cdc6b7427","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.4.2.tgz","integrity":"sha512-zRiA8J00xz2Lknr9rugKW/a1yaS3BEPXH5Ahd8MqGrvMBIVvecOQcZHa1oy12+gBaMDmNdWy4Btj/1k8c+haxA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDo7o3kzaiGaeHmoY6GMsv1hjlXw/GTTXpryTk6qSfR7AiAbnw9PjoaZ+lICy4wvqoRVyzleOrAJhF/bJlVf+qNXLQ=="}]},"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/in-viewport-3.4.2.tgz_1478821043731_0.5875834033358842"}},"3.5.0":{"name":"in-viewport","version":"3.5.0","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"^12.0.1","closurecompiler":"^1.5.2","deumdify":"^1.2.2","merge":"1.2.0","watchify":"^3.6.1","zuul":"^3.11.0","zuul-ngrok":"^4.0.0"},"gitHead":"46aa0be7cb688613213b16693d4501b61071d45e","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport#readme","_id":"in-viewport@3.5.0","_shasum":"28bad42e29e8c89d71386f9847aac9fca527b81a","_from":".","_npmVersion":"4.2.0","_nodeVersion":"7.10.0","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"dist":{"shasum":"28bad42e29e8c89d71386f9847aac9fca527b81a","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.5.0.tgz","integrity":"sha512-+F00YnayzDmvxIqUxy7lV4vPgsIC3gJB5nMxmXGHoJozzdX8oNAjpfzvrRvmhKFLX3mvFm60qT1mIHK0NW9Nkw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCXWsRaA9/ChORH14KzjcAmWlcpjNgy+ZOBtCz8OVqeiQIhAL6plhdDVUJKONKeJxbdD6HjYLMxujtcUJpvKDu4O/Ij"}]},"maintainers":[{"name":"tzi","email":"thomas@zilliox.me"},{"name":"vvo","email":"vincent.voyer@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/in-viewport-3.5.0.tgz_1494783454370_0.9104707790538669"}},"3.6.0":{"name":"in-viewport","version":"3.6.0","description":"Get a callback when an element enters the viewport (body) or a custom viewport","main":"./in-viewport.js","scripts":{"build":"browserify ./in-viewport.js -s inViewport -p deumdify | ccjs - > build/in-viewport.min.js","watch":"watchify ./in-viewport.js -d -s inViewport -p deumdify -o build/in-viewport.min.js -v","dev":"npm run watch & DEBUG=zuul* zuul --local 8080 -- test/*.js","test":"npm run build && DEBUG=zuul* zuul --tunnel ngrok -- test/*.js"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"license":"MIT","devDependencies":{"browserify":"^12.0.1","closurecompiler":"^1.5.2","deumdify":"^1.2.2","merge":"1.2.0","watchify":"^3.6.1","zuul":"^3.11.0","zuul-ngrok":"^4.0.0"},"gitHead":"3a97fc8f055611830e855b4306dfd65683de99f7","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"homepage":"https://github.com/vvo/in-viewport#readme","_id":"in-viewport@3.6.0","_npmVersion":"5.3.0","_nodeVersion":"8.5.0","_npmUser":{"name":"vvo","email":"vincent.voyer@gmail.com"},"dist":{"integrity":"sha512-MhaJ7Pr3NhUyAfpULysTZZBUAYfJAX1O8PccW2gvXlbQduMrJz7qQQ5yzC7SAr/0g5LbeRk432yNjsLMCnYzJg==","shasum":"c59b4cdcaa41adb5bf5b8fe390c7d34259891f4a","tarball":"https://registry.npmjs.org/in-viewport/-/in-viewport-3.6.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAFZU+TbQLOgCCBEyqJeGSQVpQVYqV9ZVe7CRkU+LuPoAiBHTamuMXbtY8q3DNLG2E3jorY+CUgu7rQ3DxqS/3WHKA=="}]},"maintainers":[{"name":"tzi","email":"thomas@zilliox.me"},{"name":"vvo","email":"vincent.voyer@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/in-viewport-3.6.0.tgz_1506374364847_0.8906990473624319"}}},"readme":"# inViewport [![devDependency Status](http://img.shields.io/david/dev/vvo/in-viewport.svg?style=flat-square)](https://david-dm.org/vvo/in-viewport#info=devDependencies)\n\nKnow when an element is in the window viewport or a custom viewport.\n\n[![Selenium Test Status](https://saucelabs.com/browser-matrix/in-viewportvvo.svg)](https://saucelabs.com/u/in-viewportvvo)\n\n## API\n\n### Immediate result\n\n```js\nvar inViewport = require('in-viewport');\nvar elem = document.getElementById('myFancyDiv');\n\nvar isInViewport = inViewport(elem); // returns `true` or `false`\n\nalert('myFancyDiv is ' + isInViewport ? 'visible' : 'not visible' + ' in the window');\n```\n\n### Using a callback\n\nWe watch for your element to enters the viewport and call your callback when it does.\n\n```js\nvar inViewport = require('in-viewport');\nvar elem = document.getElementById('myFancyDiv');\n\ninViewport(elem, visible);\n\nfunction visible(elt) {\n  // elt === elem\n  alert(elt.id + ' is visible in the window!');\n}\n```\nThe first callback argument is always the `element` that entered the viewport.\n\n### Callback watcher API\n\nThe callback is called only one time, when the `element` is in the viewport for the first time.\nAt any time you can rewatch or stop watching, by using the `watch` and ` dispose` API.\n\n```js\nvar inViewport = require('in-viewport');\nvar elem = document.getElementById('myFancyDiv');\nvar count = 0;\nvar timer;\n\nvar watcher = inViewport(elem, visible);\n\nfunction visible() {\n  count++;\n  timer = setTimeout(watcher.watch, 1000);\n}\n\nsetTimeout(function(){\n  watcher.dispose();\n  clearTimeout(timer);\n  alert('myfancyDiv was visible '+count+' seconds in the last 10 seconds!');\n}, 10000);\n```\n\n### A custom container\n\nBy default, we use the current window as the reference viewport.\nBut you can also specify another element as a reference viewport.\n\n```js\nvar inViewport = require('in-viewport');\nvar customContainer = document.getElementById('myFancyContainer');\nvar elem = document.getElementById('myFancyDiv');\n\ninViewport(elem, { container: customContainer }, visible);\n\nfunction visible() {\n  alert('myfancyDiv is visible in the `customContainer`!');\n}\n```\n\n### Specifying an offset\n\nBy default, when your element **precisely** enters the viewport,\nyou get a callback.\n\nBut maybe you want to know when your element is **soon-to-be-shown** in the viewport?\n\nUse the `offset` param for that!\n\n```js\nvar inViewport = require('in-viewport');\nvar elem = document.getElementById('myFancyDiv');\n\ninViewport(elem, { offset: 300 }, visible);\n\nfunction visible() {\n  alert('myfancyDiv is visible in the `customContainer`!');\n}\n```\n\nWhen your element is near `300px` of the viewport, you get your callback / true result.\n\n### Specifying debounce value\n\nCurrently, scroll and resize events are called every 15ms, but there are situations where larger value like 300ms is more sensible, e.g. image lazyload, where you probably want to wait for user to stop with scrolling before loading every image that comes into viewport.\n\nYou can change that with `debounce` param.\n\n```js\nvar inViewport = require('in-viewport');\nvar elem = document.getElementById('myFancyDiv');\n\ninViewport(elem, { debounce: 300 }, visible);\n\nfunction visible() {\n  alert('myfancyDiv is visible in the `customContainer`!');\n}\n```\n\n### Failsafe check\n\nBy default, inViewport does a failsafe to handle display manipulation that does not throw an event. It works with a `setInterval` performed every 150ms.\n\nOne of the situations where this is useful is when you have a hidden parent containing elements; when the parent becomes visible, we have no event that the children became visible. If you handle cases like this by yourself in different part of your codebase (e.g. you have callback which is active when parent becomse visible), you can turn it off with `failsafe` param.\n\n```js\nvar inViewport = require('in-viewport');\nvar elem = document.getElementById('myFancyDiv');\n\ninViewport(elem, { failsafe: false }, visible);\n\nfunction visible() {\n  alert('myfancyDiv is visible in the `customContainer`!');\n}\n```\n\n### Dynamic element creation (document.createElement)\n\nIf you are creating elements dynamically, be sure to call `inViewport` when the\nelement is in the DOM.\n\nOtherwise it may fail on old browsers.\n\nWe check for newly visible elements on `scroll` or `resize`.\n\nWe use [MutationObserver](https://developer.mozilla.org/en-US/docs/Web/API/MutationObserver) to listen for newly added DOM nodes that were previously\nregistered with in-viewport.\n\nMutationObserver is not compatible with old browsers.\n\nThat is why, if you need old browsers full compatibility, you should call\nin-viewport after inserting elements in the DOM.\n\n## Use cases\n\n* Images, iframes, widgets [lazyloader](http://github.com/vvo/lazyload)\n* infinite scroll\n* loading widgets only when needed\n\n## Quirksmode\n\nBe sure to be in [standards-compliant mode](http://en.wikipedia.org/wiki/HTML5#Markup).\n\n[Quirks mode](http://en.wikipedia.org/wiki/Quirks_mode) is not supported since most browsers\nwill report invalid values for window viewport.\n\n## Developing\n\nLaunch the dev server:\n\n```shell\nnpm run dev\n```\n\nBrowse to [http://localhost:8080/__zuul](http://localhost:8080/__zuul).\n\n[Tests](test/) are written with [mocha](https://github.com/visionmedia/mocha).\n\n## Building\n\nWe provide a pre-built version of `in-viewport` in `build/in-viewport.min.js`.\n\nBut you can build your own:\n\n```shell\nnpm run build\n```\n\nYou get the build in `build/in-viewport.min.js`.\n\nPlease consider using [browserify](https://github.com/substack/node-browserify).\n\n## License\n\nCopyright (c) 2013-2016 Vincent Voyer\n\nPermission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n\"Software\"), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\nNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE\nLIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\nOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\nWITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n","maintainers":[{"name":"tzi","email":"thomas@zilliox.me"},{"name":"vvo","email":"vincent.voyer@gmail.com"}],"time":{"modified":"2022-06-19T00:58:54.984Z","created":"2013-12-22T13:22:16.918Z","0.4.0":"2013-12-22T13:22:20.442Z","0.4.1":"2014-06-06T12:38:13.271Z","0.4.2":"2014-09-11T13:51:30.330Z","1.0.1":"2015-01-25T21:01:10.433Z","3.0.2":"2015-03-14T10:16:16.677Z","3.1.0":"2015-05-23T08:22:03.313Z","3.2.0":"2015-05-24T20:03:23.643Z","3.4.0":"2015-06-02T22:37:48.562Z","3.4.1":"2015-12-14T15:34:03.202Z","3.4.2":"2016-11-10T23:37:24.245Z","3.5.0":"2017-05-14T17:37:36.574Z","3.6.0":"2017-09-25T21:19:26.024Z"},"author":{"name":"Vincent Voyer","email":"vincent.voyer@gmail.com","url":"http://github.com/vvo"},"repository":{"type":"git","url":"git://github.com/vvo/in-viewport.git"},"homepage":"https://github.com/vvo/in-viewport#readme","bugs":{"url":"https://github.com/vvo/in-viewport/issues"},"license":"MIT","readmeFilename":"README.md","users":{"amongiants":true,"ash":true,"ivangaravito":true,"monjer":true,"superwf":true,"tiberiumaxim":true}}