/**
 * Returns an xpath string with the childtag under the given parentpath for a given index.
 * Example (parentPath = '//body', childTag = 'div', index = 10) returns (//body//div)[10]
 * @param {string} parentPath
 * @param {string} childTag
 * @param {number} index
 * @type {string}
 */
export function childByIndex(parentPath, childTag, index) {
  return '(' + parentPath + '//' + childTag + ')[' + index + ']';
}

export function childElement(parent, child) {
  return parent + '//' + child;
}
