Skip to content

Latest commit

History

History
41 lines (30 loc) 路 1.38 KB

File metadata and controls

41 lines (30 loc) 路 1.38 KB

SimplEnteiner

A small, self-contained Dependency Injection (DI) framework for .NET, designed with simplicity and minimal dependencies in mind. Built from scratch using plain reflection and System.Linq.Expressions, it has no dependency on any third鈥憄arty IoC container.

Key features:

  • Fluent binding API (similar in spirit to Ninject/Autofac)
  • Scoped and hierarchical containers
  • Decorator support
  • Convention-based auto-registration
  • Reachability validation

Designed for:

  • .NET Standard 2.0+ (works in Unity, legacy projects, and modern .NET)
  • Libraries and plugins where keeping external dependencies low is important

Quick start

// DIContainer is an internal name.
DIContainer container = new DIContainer();

// ---Bindings---
// Explicit separation of registration and resolve stages
container.Bind<IService>().To<Service>().AsSingle();
container.Bind<IScopedService>().To<ScopedService>().AsScoped();
// --------------

// Required for building and validating a dependency graph.
container.Build();

IService service = container.Resolve<IService>();

Documentation and resources

馃摉 Full documentation, examples, and API reference
馃搫 License

Status

鈿狅笍 Actively developed (Beta).

  • AOT support (important for Unity IL2CPP and native publishing).