Make an object invisible

Hello, I’m trying to make my object invisible on startup. I found code on the Unity resources explaining to use a javascript script containing this code:

renderer.enabled = false;
function Update () {
}

However, this does not work.

Do you have the script attached to the object which has a mesh renderer? If you do, renderer.enabled = false, even with absolutely nothing else on the script, should disable the renderer. If its not attached to the object , then you’re going to have to tell it which objects renderer to disable.

I’d say it needs to be in the Update

function Update () {

renderer.enabled = false;
}