scripts/build/modules.js
function getDependencies(bundleType, entry) {
  const packageJson = require(path.dirname(require.resolve(entry)) +
    "/package.json")
  // Both deps and peerDeps are assumed as accessible.
  return Array.from(
    new Set([
      ...Object.keys(packageJson.dependencies || {}),
      ...Object.keys(packageJson.peerDependencies || {})
    ])
  )
}
function getDependencies(bundleType, entry) {
  const packageJson = require(path.dirname(require.resolve(entry)) +
    "/package.json")
  // Both deps and peerDeps are assumed as accessible.
  return Array.from(
    new Set([
      ...Object.keys(packageJson.dependencies || {}),
      ...Object.keys(packageJson.peerDependencies || {})
    ])
  )
}
function getDependencies ( bundleType , entry ) { const packageJson = require ( path . dirname ( require . resolve ( entry ) ) + "/package.json" ) // Both deps and peerDeps are assumed as accessible. return Array . from ( new Set ( [ ... Object . keys ( packageJson . dependencies || { } ) , ... Object . keys ( packageJson . peerDependencies || { } ) ] ) ) }
Determines node_modules packages that are safe to assume will exist.
Determines node_modules packages that are safe to assume will exist .