Simple Dependency Injection's icon

Simple Dependency Injection 1.0.0 Tools 4.3 Community

Submitted by user comfygrapes; MIT; 2025-02-13

Easily add Dependency Injection to your project.

With the plugin enabled, simply create a [DependencyProvider] node in your Main scene and assign your dependencies, then in any sub scene, so long as it is in the scene tree and has any node that has a script with an '_inject' function, add a [DependencyInjectionRequester] node.

This tool is useful in cases where:
1. You do not have direct access (via @export) to the nodes you need in a script and do not wish to create a global autoload.
2. The nodes you need have their own in-scene dependencies.
3. You wish to rely on abstractions to interact with other parts of your code.


View files Download Submit an issue Recent Edits