locator 0.0.0-dev.2 copy "locator: ^0.0.0-dev.2" to clipboard
locator: ^0.0.0-dev.2 copied to clipboard

A package that simplifies dependency injection across Luminucx applications, making resource allocation easy especially when using clean architecture.

Locator #

A package that simplifies dependency injection across Luminucx applications, making resource allocation easy especially when using clean architecture.

Getting started #

add a git ref or url of this package to your yml file as a dependency.

Features #

  • inject dependencies for later use using Locator.put
  • get injected dependencies using Locator.get

Usage #

class Service{
  final String someData;
  const Service(this.someData);
  ///... does some stuff
}

Locator().put<Service>(Service(""));

// can later now extract the instance
Locator().get<Service>().someData;
0
likes
130
points
129
downloads

Publisher

verified publisherluminucx.com

Weekly Downloads

A package that simplifies dependency injection across Luminucx applications, making resource allocation easy especially when using clean architecture.

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

More

Packages that depend on locator