Works great in Developer's Rig, but not in Hosting stage

Hi there !

I’m trying to bring up an extension that uses BabylonJS to display a 3D model (that I supply in the asset folder), but I can’t figure out why it dosen’t works in Hosted test while working perfectly fine within the Developer’s Rig. Moreover, it doesn’t even show up for viewers.

Content of Hosted asset folder :
image

Broadcaster view :

Please check the chrome console for errors.

Check additionally the following

  • your zip file contains the files not a folder with the files in
  • you included a link to the Twitch Helper JS in your code
  • you didn’t include JS from a CDN
  • you used relative links not absolute links to your JS/CSS

If it’s not a released extension then it wont show up for normal viewers.

  • your zip file contains the files not a folder with the files in

I just checked, files are at the root of the zip

  • you included a link to the Twitch Helper JS in your code

Hum, I’ll add it right away ! Should it be in viewer.js file ?

  • you didn’t include JS from a CDN

Hum, I’m kind of new to JS and Twitch Extensions programming, what is a CDN ? :sweat_smile:

  • you used relative links not absolute links to your JS/CSS

I saw a post where you highlighted this as a potential source of error, so I’ve already taken care of that !

Thanks for the heads up Dist ! How can I authorize accounts as viewers for testing ?

Extension Helper Library

An extension’s iframe must import the Extension Helper JavaScript file, created and hosted by Twitch. It provides methods for dealing with authentication, receiving notifications of stream properties, and listening to PubSub events. Each HTML defined in the Asset Hosting section of your extension (Viewer, Config, Live Config) must load the Extension Helper. To do so, include this line:

<script src="https://extension-files.twitch.tv/helper/v1/twitch-ext.min.js"></script>

You could load jQuery from code.jquery.com for example. That is jQuery’s CDN. You cannot use a CDN.

Manage an extension and look under, Versions, A Version, Access

You can enter Testing Accounts as TwitchID’s here

I’m such a klutz, I already had the helper, but as a local file (downloaded so I don’t use absolute links), can it be a problem ?

Well, since I’m including codes only from local js files, I don’t think I’m using CDN, right ?

Yeah you have to use the one from twitch itself.

Thanks, it did the trick ! (Well partially, since it seems that BabylonJS doesn’t load, but I’ll keep looking into it)