I\'m not able to get this example of using the aforementioned combo going in TypeScript.
I have and <
Importing the OrbitControls directly from the source file after importing THREE worked great for me (without using the three-orbitcontrols-ts
package):
import * as THREE from 'three';
import 'three/examples/js/controls/OrbitControls';
Using only the three
and @types/three
packages
Unfortunately none of above answers solved problem for me. I have found solution without installing third party packages by creating three.js
file with below content:
import * as THREE from 'three';
window.THREE = THREE;
require('three/examples/js/controls/OrbitControls');
export default THREE;
and then import THREE from './three'
;