importing latest THREE version with CDN

Hello,

so far, I have been using the following imports:

import * as THREE from ‘https://cdn.skypack.dev/three@0.132.2’;

import { GLTFLoader } from ‘https://cdn.skypack.dev/three@0.132.2/examples/jsm/loaders/GLTFLoader.js’;

import { FBXLoader } from ‘https://cdn.skypack.dev/three@0.132.2/examples/jsm/loaders/FBXLoader.js’;

This works fine with Firefox, but with Edge and Chrome the FBXLoader and GLTFLoader do not work.
The site just hangs.

As this may be a solved problem with later versions, I want to update to the newest THREE version (145). However, there seems to be no CDN for the examples (loaders) anywhere. I searched and tried for hours, but nothing seems to work.

So the questions is: What is the CDN link for the GLTFLoader and the FBXLoader for R145?

Thank you very much for your help!

with skypack, remove the .js from the end for threejs modules
Here is an example: https://jsfiddle.net/seanwasere/o6uxwmte

Hi Sean,

this helped :slight_smile: !

It took me a while to get it working with my coding.

The problem that I had with the Edge-browser is also solved with the R144 version :slight_smile: :smile:

There are still to things, that I do not understand:

  1. the boiler plate throws an “Uncaught Type Error” on the “import * as THREE from /‘three’/”
    even though the coding works fine???
  2. Why is it not possible to use imports in JS without the import map like in earlier versions?

The THREE documentation under three.js docs should really be updated. At least, I think it does not work anymore.

Anyway, the coding runs now, so everything is fine.

THANK YOU FOR YOUR QUICK HELP!