spaniel:LinkedInJavaScript视口跟踪库和IntersectionObserver polyfill

时间:2024-05-31 09:47:01
【文件属性】:
文件名称:spaniel:LinkedInJavaScript视口跟踪库和IntersectionObserver polyfill
文件大小:129KB
文件格式:ZIP
更新时间:2024-05-31 09:47:01
JavaScript 猎犬 LinkedInJavaScript视口跟踪库和 polyfill。 跟踪用户实际看到的内容。 import { IntersectionObserver } from 'spaniel' ; new IntersectionObserver ( ( entries ) => { console . log ( 'I see you' ) } , { threshold : 0.5 } ) . observe ( document . getElementById ( 'my-element' ) ) ; 实际用途包括: 确定广告印象 相关系统的展示次数折扣反馈 遮挡剔除-在用户接近将对象滚动到视口之前不要渲染对象 Spaniel在之上提供了其他抽象,提供了用于挂钩到低级内部的API,并且由于不完整的polyfill而受到一些限制。 通过阅读“了解更多信息。 为什么要使用
【文件预览】:
spaniel-master
----rollup.config.js(143B)
----yarn.lock(203KB)
----USAGE.md(7KB)
----src()
--------interfaces.ts(2KB)
--------native-spaniel-observer.ts(8KB)
--------native-watcher.ts(3KB)
--------utils.ts(861B)
--------index.ts(1KB)
--------spaniel-observer.ts(9KB)
--------metal()
--------watcher.ts(3KB)
--------intersection-observer.ts(7KB)
----.babelrc(47B)
----.vscode()
--------settings.json(303B)
--------tasks.json(274B)
----scripts()
--------build.sh(577B)
--------build-docs.sh(599B)
--------size-calc.js(783B)
--------publish-docs.sh(700B)
----.npmignore(39B)
----.travis.yml(1KB)
----tsconfig.json(334B)
----LICENSE(11KB)
----test()
--------setup()
--------constants.js(170B)
--------specs()
--------headless()
--------app()
----tslint.json(1KB)
----README.md(3KB)
----NOTICE(546B)
----testem.json(311B)
----.gitignore(83B)
----Brocfile.js(2KB)
----CHANGELOG.md(2KB)
----package.json(2KB)

网友评论