embed-widget

Typescript DOM library starter template

Usage no npm install needed!

<script type="module">
  import embedWidget from 'https://cdn.skypack.dev/embed-widget';
</script>

README

📦 Embed widget

Install the library as a dependency:

npm install embed-widget

Or, if you're using Yarn:

yarn add embed-widget

Then import the library:

import widget from "embed-widget";

And initialize it with an optional selector:

const embed = new widget("https://example.com", "Button text!");

You can also use a CDN:

<script src="https://unpkg.com/embed-widget"></script>