static nodePositionByAttribute_(nodes, attribute, value) {
    let index = 0;
    for (const node of nodes) {
      const attrs = node.attributes;
      const val = Number(attrs[attribute]);
      if (val === value) {
        return index;
      }
      index++;
    }
    return null;
  }
Search the node index by the t attribute
and return the index. if not found return null
@param {!Array<shaka.extern.xml.Node>} nodes
@param {!string} attribute
@param {!number} value
@return {?number}
@private