code: function getInfoFromNodeModules (presetName) {
    debug('get preset info from node_modules')
  
    const baseDir = getBaseDir()
    const packagePath = path.join(baseDir, 'node_modules', presetName, 'package.json')
  
    if (!fs.existsSync(packagePath)) {
      debug('package not exist')
      return null
    }
  
    debug(`package.json path: ${packagePath}`)
  
    const packageInfo = require(packagePath)
  
    debug('package info: %o', packageInfo)
  
    return {
      name: presetName,
      version: packageInfo.version,
      registryUrl: getRegistryUrl(packageInfo._resolved)
    }
  }
docs: 从 node_modules 中获取 preset 信息
  
  @param {string} presetName preset name
  @returns {null|PresetInfo} 结果