0

I want to add pointlight in react three fiber and it seems that it follows different syntax from usual three.js syntax.

1 Answer 1

1

All three.js objects will be treated as native JSX elements. The general rule is that React Three Fiber components are available under the camel-case version. Hence do this to add a point source light like this -

<pointLight position={[0, 10, -5]} intensity={1} color="#fff" />
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.