code: function (expression, s) {
        var openCount = 0
        var offset = 0
        var i
        var ldelim = this.ldelim
        var rdelim = this.rdelim
        var skipInWhitespace = this.autoLiteral
        var expressionAny = /^\s*(.+)\s*$/i
        var expressionTag = expression ? new RegExp('^\\s*(' + expression + ')\\s*$', 'i') : expressionAny
        var sTag
        var found
  
        for (i = 0; i < s.length; ++i) {
          if (s.substr(i, ldelim.length) === ldelim) {
            if (skipInWhitespace && (i + 1) < s.length && s.substr((i + 1), 1).match(/\s/)) {
              continue
            }
            if (!openCount) {
              s = s.slice(i)
              offset += parseInt(i)
              i = 0
            }
            ++openCount
          } else if (s.substr(i, rdelim.length) === rdelim) {
            if (skipInWhitespace && (i - 1) >= 0 && s.substr((i - 1), 1).match(/\s/)) {
              continue
            }
            if (!--openCount) {
              sTag = s.slice(ldelim.length, i).replace(/[\r\n]/g, ' ')
              found = sTag.match(expressionTag)
              if (found) {
                found.index = offset
                found[0] = s.slice(0, (i + rdelim.length))
                return found
              }
            }
            if (openCount < 0) {
              // Ignore any number of unmatched right delimiters.
              openCount = 0
            }
          }
        }
        return null
      }
docs: Find a first {tag} in the string.