title: Why is Const able to be called outside of its block scope?
body: <p>Why does calling const allowed in the following instance.</p>
  
  <pre><code>const pizza = {
  
      topping1: "ham",
      topping2: "pepperoni"
  
  }
  
  console.log(pizza.topping2);
  </code></pre>
  
  <p>technically "pizza.topping2" is outside of the curly braces. So why does it work? I figured you have to call the const somehow, however, lessons on const, state its used as a block level variable only. This might seem like a novice question( it is) however its important for me to understand the logic behind writing the syntax.</p>