PackageResolver.config constructor

  1. Map<String, Uri> packageConfigMap,
  2. {dynamic uri}

Returns the package resolution strategy for the given packageConfigMap.

If passed, uri specifies the URI from which packageConfigMap was loaded. It may be a String or a Uri.

Whether or not uri is passed, packageConfigMap is expected to be fully-resolved. That is, any relative URIs in the original package config source should be resolved relative to its location.


factory PackageResolver.config(Map<String, Uri> packageConfigMap, {uri}) =>
    new PackageConfigResolver(packageConfigMap, uri: uri).asAsync;