code: function replaceText(output, outputArray, regexp, cb) {
      var replacedOutput = output;
      outputArray.forEach(function (line, i) {
          if (0 < i) {
              replacedOutput.nl();
          }
  
          line.forEach(function (outputEntry, j) {
              if (outputEntry.style === 'block') {
                  return replacedOutput.output[replacedOutput.output.length - 1].push({
                      style: 'block',
                      args: replaceText(output.clone(), outputEntry.args, regexp, cb)
                  });
              } else if (outputEntry.style !== 'text') {
                  return replacedOutput.output[replacedOutput.output.length - 1].push(outputEntry);
              }
  
              if (regexp.global) {
                  regexp.lastIndex = 0;
              }
              var m;
              var first = true;
              var lastIndex = 0;
              var text = outputEntry.args.content;
              var styles = outputEntry.args.styles;
              while ((m = regexp.exec(text)) !== null && (regexp.global || first)) {
                  if (lastIndex < m.index) {
                      replacedOutput.text.apply(replacedOutput, [text.substring(lastIndex, m.index)].concat(styles));
                  }
  
                  cb.apply(replacedOutput, [styles].concat(m));
                  first = false;
                  lastIndex = m.index + m[0].length;
              }
  
              if (lastIndex === 0) {
                  var lastLine;
                  if (replacedOutput.output.length === 0) {
                      lastLine = replacedOutput.output[0] = [];
                  } else {
                      lastLine = replacedOutput.output[replacedOutput.output.length - 1];
                  }
  
                  lastLine.push(outputEntry);
              } else if (lastIndex < text.length) {
                  replacedOutput.text.apply(replacedOutput, [text.substring(lastIndex, text.length)].concat(styles));
              }
          }, this);
      }, this);
  
      return replacedOutput.output.map(normalizeLine);
  }
docs: Legacy alias