title: Get checkbox value from HTML in Angular 2 typescript.
body: <p>I have two checkboxes in my html as follows:</p>
  
  <pre><code>&lt;label&gt;&lt;input type="checkbox" id="checkbox1" /&gt; Folder 1: &lt;/label&gt;
  &lt;label&gt;&lt;input type="checkbox" id="checkbox2" /&gt; Folder 2: &lt;/label&gt;
  </code></pre>
  
  <p>but I'm unsure of how to retrieve the checkbox values inside my Typescript file. I know I can accomplish this by calling a separate function for each checkbox and changing a value within my typescript. However, that doesn't seem like the best way - if I had ten different checkboxes then I would need 10 different functions in my typescript.</p>
  
  <p>Is there a simply way to get whether the checkbox is on or off based on the id? Is there a better way than that? </p>