# Html video element or iframe inside the plugin

**URL:** <https://forums.creativeclouddeveloper.com/t/html-video-element-or-iframe-inside-the-plugin/3048>\
**Category:** Adobe XD\
**Created:** [June 7, 2021, 1:55pm UTC](https://forums.creativeclouddeveloper.com/t/html-video-element-or-iframe-inside-the-plugin/3048 "2021-06-07T13:55:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![adinu](https://avatars.discourse-cdn.com/v4/letter/a/d26b3c/32.png) [@adinu](https://forums.creativeclouddeveloper.com/u/adinu)\
**Post date:** [June 7, 2021, 1:55pm UTC](https://forums.creativeclouddeveloper.com/t/html-video-element-or-iframe-inside-the-plugin/3048/1 "2021-06-07T13:55:11Z")

</div>

Hi guys,

it seems like currently you don’t support adding videos/iframe to the plugin itself (tell me if i am wrong)

i tried this way

```auto
     <iframe width="420" height="315" src="https://www.youtube.com/embed/tgbNymZ7vqY"></iframe>
          <video width="750" height="500" muted autoPlay className="QuickTipsModal_video">
            <source src="Imagen de iOS_1.MOV" type="video/mp4"></source>
          </video>

```

and both examples didn’t work.

i saw you post here regarding it:

> [@Window.location change or using iframe](http://forums.creativeclouddeveloper.com/t/window-location-change-or-using-iframe/1963/2):
>
> First of all: Welcome to the forums waveslightly_smiling_face The thing is that UXP (XD’s platform for plugins) isn’t a browser and a lot of browser features aren’t fully supported. Among them are \<iframe\>'s and window locations. Therefore, solutions depend on what you’re trying to do. If you want to include a fully functional “normal” web page, that’ll probably be difficult for now. If you need a screenshot of the website (like some other plugins), you could use an online service and then…

but i wanted to clarify if you don’t support it, and when will you.

---

<div class="post-metadata">

**Author:** ![adinu](https://avatars.discourse-cdn.com/v4/letter/a/d26b3c/32.png) [@adinu](https://forums.creativeclouddeveloper.com/u/adinu)\
**Post date:** [June 8, 2021, 11:41am UTC](https://forums.creativeclouddeveloper.com/t/html-video-element-or-iframe-inside-the-plugin/3048/2 "2021-06-08T11:41:50Z")

</div>

also one more thing i want to support it lottie json files.  
i tried to install the “react-lottie” and follow the instructions but it seems like i get this error:

Plugin TypeError: Cannot set property ‘fillStyle’ of null

---

<div class="post-metadata">

**Author:** ![pklaschka](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.creativeclouddeveloper.com/pklaschka/32/3162_2.png) [@pklaschka](https://forums.creativeclouddeveloper.com/u/pklaschka)\
**Post date:** [June 8, 2021, 2:33pm UTC](https://forums.creativeclouddeveloper.com/t/html-video-element-or-iframe-inside-the-plugin/3048/3 "2021-06-08T14:33:52Z")

</div>

While only folks from Adobe are capable of answering

> [@adinu](#):
>
> and when will you.

To the best of my knowledge, indeed, there’s currently no practical way to add videos or iframes to plugins.

May I, in part out of curiosity and in part since it might lead to devs having faced similar challenges to share their solutions, ask what your Use-Case for having videos within your plugin is?

> [@adinu](#):
>
> also one more thing i want to support it lottie json files.  
> i tried to install the “react-lottie” and follow the instructions but it seems like i get this error:
> 
> Plugin TypeError: Cannot set property ‘fillStyle’ of null

While I haven’t used Lottie a lot, before, and am not too familiar with the technologies behind it, `fillStyle` looks like a canvas API ([CanvasRenderingContext2D: fillStyle property - Web APIs | MDN](https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/fillStyle)). Canvas elements, like video and iframe, aren’t supported by UXP, as of right now (a somewhat related topic that also mentions canvases is [Draw image using UXP](http://forums.creativeclouddeveloper.com/t/draw-image-using-uxp/2882)).

I’m not sure if UXP allows for alternative rendering methods where, perhaps, some might work in UXP… But since any “more complex” animation library (such as Lottie appears to be) has a heavy focus on running in browsers using some “more advanced” browser features for performance optimization, I, unfortunately, don’t believe the chances of getting it to work are high, as of right now.

Again: If you could, perhaps, write about your Use-Case, somebody might be able to share a solution 🙂

I hope that this helps, even though it’s probably not the answer you were hoping for 😉

Happy Coding,  
Pablo

---

<div class="post-metadata">

**Author:** ![adinu](https://avatars.discourse-cdn.com/v4/letter/a/d26b3c/32.png) [@adinu](https://forums.creativeclouddeveloper.com/u/adinu)\
**Post date:** [June 8, 2021, 3:39pm UTC](https://forums.creativeclouddeveloper.com/t/html-video-element-or-iframe-inside-the-plugin/3048/4 "2021-06-08T15:39:06Z")

</div>

Hi,

thank for the quick update.

the scenario is that we want to add videos to Anima product tour (the first time you will open the plugin, we want to show a flow of how to use it), we prefer adding mp4 videos/lottie because it is so smaller than gif usually.

that is our usecase.
