(function (exports) {
  'use strict';

  // Query selector helper
  function $(selector) {
    var lookup = exports.document.querySelectorAll(selector);
    return [].slice.call(lookup);
  }

  // Setup checklists
  function setupChecklists() {
    // Remove `<code>` from `li.on` and `li.off`
    $('li[class^=o] code').forEach(function (node) {
      var ul = node.parentNode.parentNode;
      var li = node.parentNode;
      var code = node;
      var isChecked = li.classList.contains('on');
      var checkbox = createCheckbox(isChecked);

      // Add `checklist` class to the list
      ul.classList.add('checklist');

      // Insert a checkbox element to the list item
      li.insertBefore(checkbox, code);

      // Remove code node
      code.remove();
    });
  }

  // Creates a simple checkbox element
  // isChecked: Whether or not it should display checked
  function createCheckbox(isChecked) {
    var checkbox = exports.document.createElement('input');
    checkbox.setAttribute('type', 'checkbox');
    checkbox.setAttribute('disabled', 'disabled');

    if (isChecked) {
      checkbox.setAttribute('checked', 'checked');
    }

    return checkbox;
  }

  setupChecklists();
})(window);

@@ -767,24 +767,464 @@
    %7D);%0A  %7D%0A%0A
+  // Setup task lists%0A  function setupTasklists() %7B%0A    $('span.done, span.todo').forEach(function (node) %7B%0A      var container = node.parentNode;%0A      var status = node;%0A      var isChecked = node.classList.contains('done');%0A      var checkbox = createCheckbox(isChecked);%0A%0A      // Add %60checklist%60 class to the task container%0A      container.insertBefore(checkbox, status);%0A%0A      // Remove task node%0A      status.remove();%0A    %7D);%0A  %7D%0A%0A
   // Creates
@@ -1631,16 +1631,36 @@
 ists();%0A
+  setupTasklists();%0A
 %7D)(windo

add support for tasks