question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Discussion] Config as Global Injectable

See original GitHub issue

Nestjs provides the opportunity to globally Inject Modules. We could create our own Eddiebot-Config-Module for example, which gets provided globally. On the other hand is the current workflow (importing the config in the files where its needed) probably easier for beginners with nestjs. What do you think about that? - This issue is meant for discussion

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:13 (10 by maintainers)

github_iconTop GitHub Comments

3reactions
naomi-lgbtcommented, May 11, 2021

You’ve heard of merge conflicts - we present GitHub’s newest feature: LABEL CONFLICTS!

2reactions
naomi-lgbtcommented, May 11, 2021

I could see the benefit of global “helper” functions (a good one being a substring function to allow us to ensure embed fields don’t exceed limits), but those could also be attached to the config object as methods.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Best way to provide configuration parameters for objects far ...
Effectively making them static/global variables. There is a 5. solution that is more in line with oo concepts: Refactor/redesign code until all ...
Read more >
Contexts and Dependency Injection - Quarkus
@ConfigProperty(name = "cool") String coolProperty;. With the notable exception of one special case discussed below, @Inject is still required for constructor ...
Read more >
Global Injection and Hooking Demo - GitHub
Open the solution in Visual Studio. Go to Build -> Batch Build... Select the following three configurations, Configuration can be Debug or Release...
Read more >
Dependency injection for filter attribute (non-global) - question
Hi, I have a Hangfire filter attribute class, which needs some dependencies via .NET Core's inbuilt DI, but the filter attribute is to...
Read more >
Is wanting a logger and configuration service "globally" in my ...
I certainly want to use logging as a service "in case" I decide to change the implementation and thought that dependency injection seemed...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found