load method

Future<ModelCollection<T>> load(
  1. Object relations
)

Eager loads relations on every model in the collection.

Implementation

Future<ModelCollection<T>> load(Object relations) async {
  if (isNotEmpty) {
    await first.modelDefinition.eagerLoad(
      this,
      relations,
      db: first.database,
    );
  }
  return this;
}