getPackageType static method

PackageType getPackageType(
  1. Map generatorConfig
)

Implementation

static PackageType getPackageType(Map<dynamic, dynamic> generatorConfig) {
  var typeStr = generatorConfig['type'];
  PackageType type;
  if (typeStr == 'module') {
    type = PackageType.module;
  } else if (typeStr == 'internal') {
    type = PackageType.internal;
  } else {
    type = PackageType.server;
  }
  return type;
}