How to connect Threejs to React?

后端 未结 5 1064
[愿得一人]
[愿得一人] 2020-12-07 16:39

I work with React and use a canvas. I want to change the canvas to WebGL (Threejs library). How to connect this library to React?

I have some element, e.g.

5条回答
  •  天涯浪人
    2020-12-07 17:42

    I know question is a tad old, but if somebody's still looking for something. You'd try https://github.com/drcmda/react-three-fiber. They've some snippet and demos on their github.

提交回复
热议问题