findLibraryByName abstract method

Future<LibraryElement?> findLibraryByName(
  1. String libraryName
)

Returns the first resolved library identified by libraryName.

A library is resolved if it's recursively accessible from the entry point or subsequent calls to libraryFor. In other words, this searches for libraries in libraries. If no library can be found, returns null.

NOTE: In general, its recommended to use libraryFor with an absolute asset id instead of a named identifier that has the possibility of not being unique.

Implementation

Future<LibraryElement?> findLibraryByName(String libraryName);