<!doctype html>
<html>
  <head>
    <title>TuparseShakur Basic Test</title>
    <link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap.min.css" />
  </head>
  <body>
    <div id="mainContainer" class="tuparse-test-container"></div>

    <!-- Point this to your requirejs file -->
    <script src="/requirejs/require.js"></script>
    <script>
      require([
        "tuparse-shakur/parser",
        "tuparse-shakur/css",
        "tuparse-shakur/dom",
        "tuparse-shakur/tests/data",
        "jquery"
      ], function (parser, css, dom, data) {
        var container = document.getElementById("mainContainer"),
          serialized;

        parser.parse(data, {
          css: {
            appendWhenDone: true
          },
          dom: {
            appendWhenDone: true,
            parentNode: container
          }
        });

        serialized = dom.serializeDom(container);

        container.innerHTML = "";

        dom.parse(serialized, {
          appendWhenDone: true
        });
      });
    </script>
  </body>
</html>
<!doctype html>
<html>
  <head>
    <title>TuparseShakur Basic Test</title>
    <link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap.min.css" />
  </head>
  <body>
    <div id="mainContainer" class="tuparse-test-container"></div>

    <!-- Point this to your requirejs file -->
    <script src="/requirejs/require.js"></script>
    <script>
      require([
        "tuparse-shakur/parser",
        "tuparse-shakur/css",
        "tuparse-shakur/dom",
        "tuparse-shakur/tests/data",
        "jquery"
      ], function (parser, css, dom, data) {
        var container = document.getElementById("mainContainer"),
          serialized;

        parser.parse(data, {
          css: {
            appendWhenDone: true
          },
          dom: {
            appendWhenDone: true,
            parentNode: container
          }
        });

        serialized = dom.serializeDom(container);

        container.innerHTML = "";

        dom.parse(serialized, {
          appendWhenDone: true,
          parentNode: container
        });
      });
    </script>
  </body>
</html>
Add parent node to reparsing
Add parent node to reparsing
