function escapedQuote(depth) {
  if (depth == 0) {
    return '"';
  } else {
    var arr = 'amp;'.repeat(depth-1);
    return '&' + arr + 'quot;';
  }
}
/**
 * Calculate the correct encoding of a quotation mark that should be used given
 * the nesting depth of the window in the frame tree.
 *
 * @param {number} depth The nesting depth of the appropriate window in the
 *     frame tree.
 * @return {string} The correctly escaped string. 
 */
Calculate the correct encoding of a quotation mark that should be used given
the nesting depth of the window in the frame tree.

@param {number} depth The nesting depth of the appropriate window in the
frame tree.
@return {string} The correctly escaped string.
Calculate the correct encoding of a quotation mark that should be used given the nesting depth of the window in the frame tree . @param { number } depth The nesting depth of the appropriate window in the frame tree . @return { string } The correctly escaped string .
function escapedQuote(depth) {
  if (depth == 0) {
    return '"';
  } else {
    var arr = 'amp;'.repeat(depth-1);
    return '&' + arr + 'quot;';
  }
}
function escapedQuote ( depth ) { if ( depth == 0 ) { return '"' ; } else { var arr = 'amp;' . repeat ( depth - 1 ) ; return '&' + arr + 'quot;' ; } }
Calculate the correct encoding of a quotation mark that should be used given
 the nesting depth of the window in the frame tree.
Calculate the correct encoding of a quotation mark that should be used given the nesting depth of the window in the frame tree .