bind<T> method

void bind<T>(
  1. T fn()
)

Implementation

void bind<T>(T Function() fn) {
  final service = fn();
  _services[T] = service;
  _defaults[T] = service;
}