Home

Awesome

Force DI

Generic dependency injection (DI) library with support for injecting Apex, Visualforce, Lightning, and Flows at runtime.

Documentation

Project Folders

The "core" framework is found in this project. This includes the following:

FolderDescription
force-diCore library, contains Injector Apex API and <c:di_injector> VF and Lightning Components

The "samples" of how to use the framework can be found in the Force-DI Samples project.

FolderDescription
force-app-1Sample application using the API and Components to inject Apex, VF and Lightning at runtime
force-app-2Sample package providing impls for various bindings above
force-app-3Sample package providing impls for various bindings above
force-di-trigger-demoSample basic trigger framework leveraging the API

Force DI Example

Other Resources on Dependency Injection Design Pattern

Some of these blogs and videos are not necessarily Salesforce-specific but give good insights on use cases and purpose behind this design pattern.

Videos

Blogs