title: What does function (i, val) mean in javascript?
body: <p>Hi guys I was just wondering what (i, val) means in this function and what it is passing?</p>
  
  <pre><code>function boldToggler(itemid) {
      $(itemid).css("font-weight", function(i, val) {
          return val == "bold" ? "normal" : "bold";
      });
  }
  </code></pre>
  
  <p>Any help would be greatly appreciated! </p>