code: function getSubmodules(packageRoot) {
    const submodules = {};
    const parentPath = resolve(packageRoot, './modules');
  
    if (fs.existsSync(parentPath)) {
      //monorepo
      fs.readdirSync(parentPath)
      .forEach(item => {
        const itemPath = resolve(parentPath, item);
        const moduleInfo = getModuleInfo(itemPath);
        if (moduleInfo) {
          submodules[moduleInfo.name] = moduleInfo;
        }
      });
    } else {
      const moduleInfo = getModuleInfo(packageRoot);
      submodules[moduleInfo.name] = moduleInfo;
    }
  
    return submodules;
  }
docs: Get information of all submodules