Skip to content

Conversation

@Urkidi
Copy link

@Urkidi Urkidi commented Nov 6, 2025

+Implemented the IServiceProvider in Container.cs
+Added new factory type implementation for Singleton, Transient, Scoped

Pull Request Template

Description

I wanted to add the possibility to translate Microsoft DI abstracted packages into Reflex. The main blockage I found was when I couldn't translate the factory bindings from Microsoft DI to Reflex. This can be easily allowed by just implementing IServiceCollection in the Container, and allowing for Func<Container, object> factory binding to exist. I wanted to know also if adding the Microsoft.Extensions.DependencyInjection.Abstractions .dll goes against the guidelines of the project.
I was just trying to make a simple bridge for IServiceCollections that loads the bindings into Reflex Containers.

Type of change

Please delete options that are not relevant.

  • [x ] New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Run PlayMode Tests
  • Run Edit Mode Tests

Test Configuration:

  • Firmware version: 2021.3.45f1
  • Hardware: LaptopRTX4070/i7-13700H
  • Toolchain: Jetbrains Rider 2025.2.4

Checklist:

  • (Not sure couldn't find the guidelines) My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
    • Additions where based on existing code. comments where deemed unnecessary
  • I have made corresponding changes to the documentation
    • I think no new changes needed to be added
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have checked my code and corrected any misspellings
  • I have checked that Reflex.GettingStarted still runs nicely

Implemented the IServiceProvider in Container.cs
Added new factory type implementations
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant