src/inflectors/spanish/noun.js
function transferCase(source, target) {
  let cased = '';

  for (let i = 0, l = target.length; i < l; i++) {
    const c = source[i].toLowerCase() === source[i] ?
      'toLowerCase' :
      'toUpperCase';

    cased += target[i][c]();
  }

  return cased;
}
function transferCase(source, target) {
  let cased = '';

  for (let i = 0, l = target.length; i < l; i++) {
    const c = source[i].toLowerCase() === source[i] ?
      'toLowerCase' :
      'toUpperCase';

    cased += target[i][c]();
  }

  return cased;
}
function transferCase ( source , target ) { let cased = '' ; for ( let i = 0 , l = target . length ; i < l ; i ++ ) { const c = source [ i ] . toLowerCase ( ) === source [ i ] ? 'toLowerCase' : 'toUpperCase' ; cased += target [ i ] [ c ] ( ) ; } return cased ; }
Function used to apply source word's case to target word.

@param  {string} source - Source word.
@param  {string} target - Target word.
@return {string}
Function used to apply source word s case to target word .