The embedSDK is available on
$ npm install @loomhq/loom-embed
It is also accessible via a script tag you can put directly into your HTML.
import * as loomEmbedSDK from "https://www.unpkg.com/@email@example.com/dist/esm/index.js?module";
With a given Loom URL you can use the
oembed method to fetch metadata about the video. This metadata includes an
html property which can be used to set the inner HTML of a DOM node.
There is also a
textReplace method which will replace Loom URLs in a given string with the embeddable HTML.
Unfurling Loom links
To expand a Loom URL directly, you can use the
linkReplace method which targets a provided selector—such as
'.loom-video' for example—and inserts the embed player on your page.