Using babylon.JS in a Twitch extension

Hello there !

I am currently trying to use babylon.JS to render and select parts of a 3D model in a Twitch extension.

The thing is, it works perfectly fine when I host locally my front-end (which uses babylon.JS), but as soon as I try to make some hosted test (meaning I send my http, js and gltf files to the Twitch CDN), it doesn’t work anymore… (as you can see on this picture, only my html button is visible, while the babylon.JS part above doesn’t even show up).

Does anybody might know why, and how to prevent this problem ?

Do you have any error in the console? anything that can give us an idea of what the problem could be?

I’m such a klutz, I’m new to web dev and I didn’t think of checking the console…

Here is the outcome :

The content of my file video_component.html is the following : [HTML 5] video_component.html - Pastebin.com

Okay, so basically I’m just a bad coder (or as stated before, a newb in web dev), I used chunks of JS directly inside my HMTL file.

I just popped it out in a separate JS file and now it works like a charm !

Don’t be too hard on you. The only thing that matters is learning!

2 Likes