code: function stripLinkDefinitions(text) {
  
          var text = text.replace(/^[ ]{0,3}\[(.+)\]:[ \t]*\n?[ \t]*<?(\S+?)>?[ \t]*\n?[ \t]*(?:(\n*)["(](.+?)[")][ \t]*)?(?:\n+|\Z)/gm, function (wholeMatch,m1,m2,m3,m4) {
              m1 = m1.toLowerCase();
              urls[m1] = encodeAmpsAndAngles(m2);
              if (m3) {
                  return m3+m4;
              } else if (m4) {
                  titles[m1] = m4.replace(/"/g,"&quot;");
              }
              return "";
          });
  
          return text;
      }
docs: {{{ stripLinkDefinitions