function createComponentMainKey(tempRef, mainKeys) {
  let newKey = generateObjectName(tempRef),
    mainKey = mainKeys[newKey];
  if (mainKey && mainKey !== tempRef) {
    newKey = createComponentHashedKey(tempRef);
  }
  return newKey;
}
Generates a not repeated mainKey for the component
@param {string} tempRef - The reference to the node we are processing
@param {array} mainKeys - A list of previous generated mainKeys
@returns {string} A generated mainKey from the provided tempRef