dotnet / dotnet-api-docs

.NET API reference documentation (.NET 5+, .NET Core, .NET Framework)
https://docs.microsoft.com/dotnet/api/
Other
737 stars 1.57k forks source link

Extension methods section for IServiceCollection is overwhelming #10443

Open ericstj opened 1 month ago

ericstj commented 1 month ago

Describe the issue or suggestion

@sixpi was sharing their experience with me about trying to learn about DI and brought up the problem that IServiceCollection lists 456 extension methods: https://learn.microsoft.com/en-us/dotnet/api/microsoft.extensions.dependencyinjection.iservicecollection?view=net-8.0#extension-methods

This is way too much and can be overwhelming.

I think it the docs tooling was able to collapse extension methods that have a common name into a single entry it would help - this would reduce from 456 -> 156 entries. Also grouping by the type of the "this" parameter would also be helpful - this would show that there are only 76 method groups for IServiceCollection and the remaining are for IEnumerable*/IList*

cc @gewarren

dotnet-policy-service[bot] commented 1 month ago

Tagging subscribers to this area: @dotnet/area-system-collections

dotnet-policy-service[bot] commented 1 month ago

Tagging subscribers to this area: @dotnet/area-extensions-dependencyinjection

gewarren commented 1 month ago

@ericstj The Learn platform team has a new intake request form here. Can you add a request?

As FYI, here a couple existing requests to improve display of extension methods:

ericstj commented 1 month ago

Both of those seem like bugs to me rather than feature / design change. I couldn't find an issue requesting better grouping which is why I opened this one. I'll fill out the requeest.