# from<T> static method

BootstrapInstanceSupplier<T> from<T>(

1. T supplier()

)

Creates a supplier from a function that returns a new instance.

Example:

    final supplier = InstanceSupplier.from(() => MyService());

The scope defaults to `SINGLETON`, but can be changed with withScope.

## Implementation

    static BootstrapInstanceSupplier<T> from<T>(T Function() supplier) => _IS<T>(supplier);