transformedDirectiveAsts property
List<DirectiveAst>
get
transformedDirectiveAsts
Implementation
List<DirectiveAst> get transformedDirectiveAsts {
final providers = _transformedProviders.values
.map((provider) => provider.token.identifier)
.toList();
// Directives must be sorted according to the dependency graph between them.
// For example, if directive A depends on directive B, then directive B must
// be instantiated before A so that it's available for injection into A.
return List.of(_directiveAsts)
..sort((a, b) =>
providers.indexOf(a.directive.type) -
providers.indexOf(b.directive.type));
}