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 Answer 1

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.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.