Click here to Skip to main content
15,893,994 members
Articles / Programming Languages / C#

Enhanced C# IHostBuilder/IHost and Dependency Injection Resolver Libraries

Rate me:
Please Sign up or sign in to vote.
5.00/5 (4 votes)
8 Jan 2023GPL35 min read 20.5K   8  
An Autofac-based chained/declarative approach to creating an IHostBuilder/IHost and a generalized dependency injection resolver
I like the IHostBuilder/IHost approach for structuring applications. But I find configuring the necessary IHostBuilder confusing. There are also certain functionalities, like logging and encryption/decryption of configuration values, which I use so often I wanted them to be easily includable in an IHost. The J4JHostConfiguration library is my attempt to accomplish all of this. It also supports creating a dependency injection resolver object you can use in any C# application which lacks a built-in DI resolver.

Views

Daily Counts

License

This article, along with any associated source code and files, is licensed under The GNU General Public License (GPLv3)


Written By
Jump for Joy Software
United States United States
Some people like to do crossword puzzles to hone their problem-solving skills. Me, I like to write software for the same reason.

A few years back I passed my 50th anniversary of programming. I believe that means it's officially more than a hobby or pastime. In fact, it may qualify as an addiction Smile | :) .

I mostly work in C# and Windows. But I also play around with Linux (mostly Debian on Raspberry Pis) and Python.

Comments and Discussions