Dependency injection

This page summarizes the projects mentioned and recommended in the original post on /r/QtFramework

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • fruit

    Fruit, a dependency injection framework for C++

  • Hey, I'm making a "bigger" application and I am using Dependency Inversion to separate different layers of my application. I was looking into Dependency Injection frameworks for c++ to simplify this process. I found google fruit (https://github.com/google/fruit) which looks decent, but I dont have much experience with this DI (in c++). Did anyone work with something similar and could give me advice on this topic or recommend me another library for this?

  • lager

    C++ library for value-oriented design using the unidirectional data-flow architecture — Redux for C++

  • My preferred approach is to abstract things so the boundary between the objects is not a function call, but a value being passed. This was shown to me the first time via Boundaries (from Gary Bernhadt). In C++ world, the talks from Juan Pedro Bolívar Puente are great, as he also is the author of a framework to structure applications that way, the framework is open source, and it's been used in production applications, probably using Qt as well. I would start by watching The Most Valuable Values and Squaring the Circle. If you prefer text, go read Lager's excellent documentation.

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • kangaru

    🦘 A dependency injection container for C++11, C++14 and later

  • This Fruit library is still on my TO-DO to review and try, but there is one other library that I wanted to try first, and it's called Kangaru. Both are DI injectors, but I can't say much more about them yet.

  • Experimental Boost.DI

    C++14 Dependency Injection Library

  • I was looking to try boost.di for some time, looks nice. https://boost-ext.github.io/di/

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts