async function loadAppDescriptors(appNames, pathFolders) {
  const descriptors = new Map();
  const descriptorQueue = appNames.slice(0);
  while (descriptorQueue.length) {
    const name = descriptorQueue.shift();
    if (descriptors.has(name))
      continue;
    const source = await loadSource(pathFolders, name + '.json');
    const content = JSON.parse(source);
    const descriptor = {
      name: name,
      modules: content.modules || [],
      hasHtml: content.has_html || false,
    };
    if (content.extends) {
      descriptor.extends = content.extends;
      descriptorQueue.push(descriptor.extends);
    }
    descriptors.set(name, descriptor);
  }
  return descriptors;
}
@param {!Array<string>} appNames
@param {!Array<string>} pathFolders
@return {!Promise<!Map<string, !AppDescriptor>>}