title: How to Hide/Show Objects using Three.js release 54?
body: <p>I've asked this question as a part of Huge question but was recommended to ask in parts. Here comes the part of my previous question. My previous question was: <a href="https://stackoverflow.com/questions/14115733/how-to-perform-picking-and-hiding-objects-using-three-js#comment19536453_14115733">Here</a></p>
  
  <p>I've been using Three.js Release 50 and able to show/hide the objects (In my application, it is a mesh child) with the help of:</p>
  
  <pre><code>THREE.SceneUtils.traverseHierarchy(mesh,function(child){
  var z = document.getElementById("cameras").selectedIndex*5 -10;
  if (z === -10){
      child.visible = true;
  } else if (child.position.z !== z){
      child.visible = false;
  } else {
  
      child.visible = true;
  };
  }); 
  </code></pre>
  
  <p>But while using release 54, it is said that to use, object.traverse but found very difficult to the same. How to replace the above code using release 54? The error I'm getting while using release 54 is:</p>
  
  <p><img src="https://i.stack.imgur.com/fVWFr.jpg" alt="enter image description here"></p>
  
  <p>Please help me to sort this out.</p>