Getting started with web components
Our web components are a faster and more powerful alternative for embedding your Wavekit content on your website.
When using an <iframe> you're basically loading a new website for every audio player. Web components load our players straight into your website with no overhead.
Our components are in beta. If you'd like to try them out, contact us at hello@wavekit.app so we can enable your domain.
Installation#
To be able to use these components you first need to import our JavaScript file from our edge CDN inside your <head>.
<script src="https://js.wavekit.app/wavekit-2.2.0.js"></script>
Content security policy#
If you have a strict CSP you will need to add a DNS record to your domain so that the browser trusts our JavaScript. Add a CNAME record for eg wavekit.yourdomain.com pointing to js.wavekit.app and then use your subdomain for the URL:
<script src="https://wavekit.yourdomain.com/wavekit-2.2.0.js"></script>
Again, contact us at hello@wavekit.app so we can enable the SSL for your domain.
Browser support#
Web components have broad support and are used in production by major websites like Youtube and Reddit. We're following the Custom Elements v1 spec which has been supported by major browsers since 2016.