AsyncImportCache constructor
AsyncImportCache({
- Iterable<
AsyncImporter> ? importers, - Iterable<
String> ? loadPaths, - PackageConfig? packageConfig,
- Logger? logger,
Creates an import cache that resolves imports using importers
.
Imports are resolved by trying, in order:
-
Each importer in
importers
. -
Each load path in
loadPaths
. Note that this is a shorthand for adding FilesystemImporters toimporters
. -
Each load path specified in the
SASS_PATH
environment variable, which should be semicolon-separated on Windows and colon-separated elsewhere. -
package:
resolution usingpackageConfig
, which is aPackageConfig
from thepackage_config
package. Note that this is a shorthand for adding a PackageImporter toimporters
.
Implementation
AsyncImportCache(
{Iterable<AsyncImporter>? importers,
Iterable<String>? loadPaths,
PackageConfig? packageConfig,
Logger? logger})
: _importers = _toImporters(importers, loadPaths, packageConfig),
_logger = logger ?? Logger.stderr();