Cannot read property 'setJSMaterials' of undefined

See original GitHub issue

Hi,

I keep getting this error in my ios app, not really sure how to resolve it:

Cannot read property 'setJSMaterials' of undefined

Function.createMaterials
    ViroMaterials.js:71:20
<unknown>
    HelloWorldSceneAR.js:68:14
loadModuleImplementation
    require.js:214:4
guardedLoadModule
    require.js:148:11
_require
    require.js:132:2
<unknown>
    App.js:33:21
loadModuleImplementation
    require.js:214:4
guardedLoadModule
    require.js:148:11
_require
    require.js:132:2
<unknown>
    index.js:2

Any help would be appreciated.

Thanks

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:14 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
faisal3413commented, Jul 17, 2018

If you still get some build errors after following the guide, make sure you open the xcworkspace instead of xcodeproj as viro react is using coca pods.

2reactions
VikAdvanicommented, Jul 5, 2018

Hi @faisal3413,

  1. Did you create your project running ‘react-viro init’??
  2. Did you run the script ‘./setup-ide --all’ in your project directory?
  3. If you did 2), what was the output of that script, can you cut and paste that here?
  4. Did you modify the sample code in anyway?

Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot read property 'setTitle' of null, js engine: hermes
We have to restart with the command react-native run-android .It worked for me,there is no need to removing node modules or cache.
Read more >
Can Not Read Properties of Undefined Reading Map in React ...
If you are looking at can not read properties of undefined reading map in react js error or map function is not displaying...
Read more >
can not read properties of undefined | app showing blank page
Your browser can't play this video. ... can not read properties of undefined | reading render error in react | app showing blank...
Read more >
Troubleshooting - React Navigation
I'm getting an error "TypeError: Cannot read property 'bind' of undefined" or "TypeError: propListener.apply is not a function"​.
Read more >
Cannot read property of undefined? Weird : r/reactjs - Reddit
So, when calling an API, I'm getting an error that it can't read property "en" of undefined. Here is the code: function Coin()...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found