Skip to content

Instantly share code, notes, and snippets.

@khellang
Last active July 14, 2016 21:35
Show Gist options
  • Save khellang/caed891cfe72417239db3d199b894633 to your computer and use it in GitHub Desktop.
Save khellang/caed891cfe72417239db3d199b894633 to your computer and use it in GitHub Desktop.

Current Adapters

  • StructureMap.Dnx
  • Autofac.Extensions.DependencyInjection
  • DryIoc.AspNetCore.DependencyInjection
  • Grace.DependencyInjection.Extensions
  • LightInject.Microsoft.DependencyInjection

Proposed StructureMap Alternatives

Microsoft.Extensions.DependencyInjection.StructureMap

This is the most common naming scheme in the .NET space; <product>.<extension/adapter>, but it has two issues:

  • It looks like it comes from Microsoft
  • Is's a horribly long name

StructureMap.Microsoft.Extensions.DependencyInjection

Follows the same convention as above, but has the "relationship" flipped around. This gets rid of the first issue, but it's still really really long.

StructureMap.Microsoft.DependencyInjection

Follows the LightInject precedent and is also @davidfowl's favorite. It's a bit shorter than the name above.

StructureMap.Extensions.DependencyInjection

This follows the Autofac precedent, but has the following issues:

  • It sounds like it's an extension to make StructureMap do dependency injection, which it clearly already does just fine.
  • It's also a bit long

StructureMap.DependencyInjection.Extensions

Follows the Grace precedent, but has same issues as Autofac.

StructureMap.AspNetCore.DependencyInjection

Follows the DryIoc precedent, but has the following issues:

  • It implies that it's ASP.NET Core only, which it isn't. This is why the main package is called Microsoft.Extensions.DependencyInjection, and not Microsoft.AspNetCore.DependencyInjection
  • It's has the DependencyInjection suffix, which in my opinion is redundant
  • It's also too long

StructureMap.AspNetCore

A nice, short name, but suffers from the first point above.

@joaofx
Copy link

joaofx commented Jul 14, 2016

I don't know if it makes sense, but when I see Microsoft in a nuget package name, I think that is maintained by Microsoft.

@cwe1ss
Copy link

cwe1ss commented Jul 14, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment