github.com/xmidt-org/arrange (go): Package arrange enhances uber/fx with extra features common in server-side use of dependency injection.  It's often useful to bootstrap one or more uber/fx components with state read from external configuration sources.  Arrange integrates with github.com/spf13/viper and supports unmarshaling components and injecting them into an fx.App.  Consider the case of reading in some configuration.  Arrange allows you to easily unmarshal configuration into a struct, then use that struct as a dependency:  Configuration keys are also supported:  Arrange also exposes a way to unmarshal several keys to the same type, which is commonly done when multiple components, such as http.Server objects, need to get bootstrapped:  See the examples for additional features.  When creating an fx.App, it can be useful to conditionally include options based on external sources of information, such as the command-line, the environment, or even viper.  Arrange exposes a very simple API that makes conditional options simple and easy.  It's often desirable to redirect the DI container's logging output, which contains information about the dependency graph, to some other location.  Arrange provides easy integration with logging frameworks like go.uber.org/zap:
Keywords: hacktoberfest