0

Can someone tell me how I can combine three.js code with react-three-fiber? I saw that tag is useful in such cases but still can't understand how.

1 Answers1

1

Import Three to use related stuff, like this

import * as THREE from 'three'

Then you can access THREE stuff such as THREE.Vector3

ideally you would want to write your three code in a hook like useEffec or useFrame or in any another way whichever is relevant.

Epiczzor
  • 377
  • 2
  • 13