内容简介:A web component which enhances user experience by lazy loading iframes and providing a better fallback user interface
<lite-iframe />
A web component which enhances user experience by lazy loading iframes and providing a better fallback user interface
View Demo · Report Bug · Request Feature
About The Project
Built With
Getting Started
To get a local copy up and running follow these simple steps.
- Install NPM packages
npm install lite-iframe
- Include the
lite-iframecomponent file in your project root.
import 'lite-iframe';
OR
- You can include unpkg CDN link in the project file.
<script src="https://unpkg.com/lite-iframe@0.2.0/dist/lite-iframe.esm.js" type="module" ></script>
Usage
You can use lite-iframe like normal iframe.
<!-- Codepen --> <lite-iframe scrolling="no" title="Piccalilli CSS Utility — Issue #2 — Full bleed utility" src="//codepen.io/andybelldesign/embed/Nmxrwv/?height=300&theme-id=dark&default-tab=css,result" frameborder="no" allowtransparency="true" allowfullscreen="true" > </lite-iframe> <!-- Youtube --> <lite-iframe type="youtube" src="https://www.youtube.com/embed/lzQyH-nX0u0" ></lite-iframe>
For live example, please see the demo
Contributing
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated .
git checkout -b feature/AmazingFeature git commit -m 'Add some AmazingFeature' git push origin feature/AmazingFeature
License
Distributed under the MIT License. See LICENSE for more information.
Contact
Annamalai Saravanan - @asvny_
Project Link: https://github.com/asvny/lite-iframe
Acknowledgements
以上所述就是小编给大家介绍的《
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
Ajax基础教程
(美)阿斯利森、(美)舒塔、金灵 / 金灵 / 人民邮电出版社 / 2006-02-01 / 35.00元
Ajax技术可以提供高度交互的Web应用,给予用户更丰富的页面浏览体验。本书重点介绍Ajax及相关的工具和技术,主要内容包括XMLHttpRequest对象及其属性和方法、发送请求和处理响应、构建完备的Ajax开发工具、使用JsUnit测试JavaScript、分析JavaScript调试工具和技术,以及Ajax开发模式和框架等。本书中所有例子的代码都可以从Apress网站本书主页的源代码(Sou......一起来看看 《Ajax基础教程》 这本书的介绍吧!