I’m new to web development and Three.js. I need to embed all my JavaScript code inside my HTML file without using separate .js files. Currently, I’m using module import statements for Three.js, OrbitControls, and GLTFLoader, in a seperate .js file, but when I try to move the entire code inside the HTML, and add CDN’s Like so: https://tutuappx.com/ Vidmate
<!-- Include Three.js core library -->
<script src="https://cdn.skypack.dev/three@0.129.0/build/three.module.js"></script>
<!-- Include GLTFLoader module for loading 3D models in glTF format -->
<script src="https://cdn.skypack.dev/three@0.129.0/examples/jsm/loaders/GLTFLoader.js"></script>
<!-- Include OrbitControls module for interactive camera controls -->
<script src="https://cdn.skypack.dev/three@0.129.0/examples/jsm/controls/OrbitControls.js"></script>
The script is not loading the gltf. Are the CDNs wrong or is it simply not possible? If yes, Alternatively is there a workaround to this?