title: How to toggle a boolean?
body: <p>Is there a really easy way to toggle a boolean value in <strong>javascript</strong>?</p>
  
  <p>So far, the best I've got outside of writing a custom function is the ternary:</p>
  
  <pre><code>bool = bool ? false : true;
  </code></pre>