0.4.0 • Published 8 months ago
@marcopns/lite-vimeo v0.4.0
What does this fork do:
- Add dnt parameter to the iframe
- Add hash parameter to the iframe
- Add option to include more parameters to the iframe (https://github.com/luwes/lite-vimeo-embed/pull/24)
How to use it instead of the OG Version?
Remove the OG version from your project and install the package like this and you're good to go.
npm install @marcopns/lite-vimeoOG Readme: Lite Vimeo Embed
Renders faster than a sneeze.
Provide videos with a supercharged focus on visual performance. This custom element renders just like the real thing but approximately 224X faster.
Comparison
Normal <iframe> Vimeo embed | lite-vimeo |
|---|---|
![]() | ![]() |
Basic usage
To use the custom embed you will need to:
- Include the script
- Use the element
lite-vimeomarkup and scripting - Be happy that you're providing a better user experience to your visitors
<!-- Include the custom element script -->
<script type="module" src="https://cdn.jsdelivr.net/npm/lite-vimeo-embed/+esm"></script>
<!-- Use the element. You may define uses before the scripts are parsed and executed. -->
<lite-vimeo videoid="357274789"></lite-vimeo>Pro-usage
Use this as your HTML, load the script asynchronously, and let the JS progressively enhance it.
<lite-vimeo videoid="357274789" style="background-image: url('https://i.vimeocdn.com/video/810965406.webp?mw=1600&mh=900&q=70');">
<div class="ltv-playbtn"></div>
</lite-vimeo>0.4.0
8 months ago

