Open mocon opened 7 years ago
yes same thing here what's wrong
import React, { Component } from 'react'
import { render } from 'react-dom'
import 'aframe'
import 'aframe-particle-system-component'
import { Entity, Scene } from 'aframe-react'
class App extends Component {
render () {
return (
<Scene>
<Entity geometry={{primitive: 'box'}} material={{color: 'red'}} position={{x: 0, y: 0, z: -5}}/>
<Entity particle-system={{preset: 'snow'}}/>
<Entity light={{type: 'point'}}/>
<Entity gltf-model={{src: 'virtualcity.gltf'}}/>
<Entity text={{value: 'Hello, WebVR!'}}/>
</Scene>
);
}
}
Meteor.startup(function () {
const app = document.getElementById('app')
render(<App />, app)
})
the error goes after i removed this line
<Entity gltf-model={{ src: 'virtualcity.gltf' }}/>
same here. But what if we need to load a glTF file?
I think this is just a typo in the example code.
Removing the dictionary such that the gltf-model
attribute is set to a URL string (instead of an object containing a src
property) seems to work fine for me, e.g.
<Entity gltf-model={'virtualcity.gltf'}/>
<Entity gltf-model="virtualcity.gltf"/>
Hi, wich version of Aframe are you using? I was having the same problem and this last answer from @psigen worked for loading the gltf asset without throwing directory parsing error, anyway my models are showing as empty entities.
I'm using "dependencies": {
"aframe": "^0.8.2",
"aframe-react": "^4.4.0",
}
Hello. I'm seeing the following error right after install:
Am I doing something wrong, or is this a bug? Thanks!