Parent not specified when trying to embedding everything

Ok so I am building myself a website and would like to embed the twitch player that includes everything. I am trying to follow the instructions for “Embedding Everything” ( and I am trying to test locally by just running my html file from the file directory but I keep getting the parent not specified in my chrome console.

I am not sure what I am missing:

   <!-- Add a placeholder for the Twitch embed -->
    <div id="twitch-embed"></div>

    <!-- Load the Twitch embed script -->
    <script src=""></script>

      Create a Twitch.Embed object that will render
      within the "twitch-embed" root element.
    <script type="text/javascript">
      var embed = new Twitch.Embed("twitch-embed", {
        width: 854,
        height: 480,
        channel: "hottahdy",
        layout: "video-with-chat",
        autoplay: true,
        muted: true

      embed.addEventListener(Twitch.Embed.VIDEO_READY, () => {
        var player = embed.getPlayer();;

You can’t run it from the file. It needs to be loaded from a web server. Local host works. But a public website needs SSL also.

Yep that did it, I just had to turn my pc in a local web server.

Thank you for the help!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.