supermedium / aframe-react

:atom: Build virtual reality experiences with A-Frame and React.
https://ngokevin.github.io/aframe-react-boilerplate/
MIT License
1.42k stars 151 forks source link

Let's provide the primitives #49

Closed jonasfj closed 7 years ago

jonasfj commented 7 years ago

As I understand primitives: https://aframe.io/docs/0.4.0/primitives/

They are just a-entity tags with a nice combination of components and default values, as well a easy access attributes.

We could probably implement them all very quickly, any reason not to provide them?

ngokevin commented 7 years ago

What would be the reason to provide them? They are usable as is from aframe-react, there's even a primitive prop.

jonasfj commented 7 years ago

I couldn't do <Entity id="pine" primitive="a-collada-model" src="#pine2" position="0 0 -15" /> For some reason the src property isn't passed down... I think had similar issues with other primitives.

Maybe I'm missing something, or maybe we're missing that specific property somewhere... I'll admit anything 3d is far outside my comfort zone - I'm just having some holiday fun :)

ngokevin commented 7 years ago

There was a PR today to fix primitives, there was a typo, I released that version

You could also just use <a-collada-model>.

Hope it's fun :)

jonasfj commented 7 years ago

Oh, I didn't know that worked in react... nevermind :)