Skip to content

DI article overhaul#36816

Open
guardrex wants to merge 3 commits intomainfrom
guardrex/di-article-overhaul
Open

DI article overhaul#36816
guardrex wants to merge 3 commits intomainfrom
guardrex/di-article-overhaul

Conversation

@guardrex
Copy link
Collaborator

@guardrex guardrex commented Feb 27, 2026

Fixes #35804

Tom ... Ready for review.

  • I assume that you'd like to keep the author byline.
  • Razor component examples added with cross-links to relevant Blazor article sections.
  • General edits and improvements, including for the example code.
  • I 💀 the crappy, old samps here. I moved them to the samples repo. I recommend inlining the code here for these examples.
  • I also 💀 the INCLUDES files 🤮.

This link should get you to the diff file for the article 👉 aspnetcore/fundamentals/dependency-injection.md.


Internal previews

📄 File 🔗 Preview link
aspnetcore/fundamentals/dependency-injection.md aspnetcore/fundamentals/dependency-injection

@guardrex guardrex self-assigned this Feb 27, 2026
@guardrex guardrex requested a review from Copilot March 3, 2026 17:49
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR overhauls the DI docs content by removing legacy in-repo sample apps and older monikered include files, with the intent to rely on newer examples and/or relocated samples.

Changes:

  • Removed multiple legacy sample projects and their static web assets under aspnetcore/fundamentals/dependency-injection/samples/*.
  • Deleted older monikered include articles (dependency-injection-8.md, dependency-injection-5-7.md) that previously carried most of the DI topic content.
  • Cleaned out third-party library license files that were stored alongside the removed sample assets.

Reviewed changes

Copilot reviewed 160 out of 210 changed files in this pull request and generated no comments.

Show a summary per file
File Description
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/wwwroot/lib/bootstrap/LICENSE Removed Bootstrap license file from legacy sample assets
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/wwwroot/js/site.js Removed legacy sample static JS
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/wwwroot/css/site.css Removed legacy sample static CSS
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/appsettings.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/appsettings.Development.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Services/OperationService.cs Removed legacy DI lifetime sample code
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Services/MyDependency.cs Removed legacy DI sample services
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/ProgramEF.cs Removed legacy EF/Identity registration sample
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Program.cs Removed legacy multi-#if sample host code
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/_ViewStart.cshtml Removed legacy Razor Pages layout setup
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/_ViewImports.cshtml Removed legacy Razor Pages imports
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Shared/_ValidationScriptsPartial.cshtml Removed legacy validation script partial
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Shared/_Layout.cshtml Removed legacy Razor Pages layout
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Privacy.cshtml.cs Removed legacy Razor Page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Privacy.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index5.cshtml.cs Removed legacy DI usage example page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index5.cshtml Removed legacy DI usage example page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index4.cshtml.cs Removed legacy operations lifetime page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index4.cshtml Removed legacy operations lifetime page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index2.cshtml.cs Removed legacy DI usage example page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index2.cshtml Removed legacy DI usage example page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index.cshtml.cs Removed legacy lifetime logging page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Index.cshtml Removed legacy lifetime logging page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Error.cshtml.cs Removed legacy error page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/Error.cshtml Removed legacy error page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/About.cshtml.cs Removed legacy logging sample page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Pages/About.cshtml Removed legacy page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Models/Operation.cs Removed legacy operation implementation
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Middleware/MyMiddleware.cs Removed legacy middleware lifetime sample
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Interfaces/IOperation.cs Removed legacy operations interfaces
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/Interfaces/IMyDependency.cs Removed legacy DI interface
aspnetcore/fundamentals/dependency-injection/samples/6.x/DependencyInjectionSample/DependencyInjectionSample.csproj Removed legacy sample project
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/lib/jquery/LICENSE.txt Removed jQuery license file from legacy sample assets
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/lib/jquery-validation/LICENSE.md Removed jQuery Validation license file
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/lib/jquery-validation-unobtrusive/jquery.validate.unobtrusive.js Removed bundled third-party JS from legacy sample
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/lib/jquery-validation-unobtrusive/LICENSE.txt Removed third-party license file
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/lib/bootstrap/LICENSE Removed Bootstrap license file
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/js/site.js Removed legacy sample static JS
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/css/site.css Removed legacy sample static CSS
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/appsettings.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/appsettings.Development.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Program.cs Removed legacy sample host code
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/_ViewStart.cshtml Removed legacy Razor Pages layout setup
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/_ViewImports.cshtml Removed legacy Razor Pages imports
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Shared/_ValidationScriptsPartial.cshtml Removed legacy validation script partial
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Shared/_Layout.cshtml Removed legacy Razor Pages layout
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Privacy.cshtml.cs Removed legacy Razor Page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Privacy.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Index.cshtml.cs Removed legacy example with direct instantiation
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Index.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Error.cshtml.cs Removed legacy error page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/Pages/Error.cshtml Removed legacy error page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/MyDependency.cs Removed legacy dependency class used in docs
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/DIwebApp.csproj Removed legacy sample project
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/wwwroot/lib/jquery/LICENSE.txt Removed jQuery license file from legacy sample assets
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/wwwroot/lib/jquery-validation/LICENSE.md Removed jQuery Validation license file
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/wwwroot/lib/jquery-validation-unobtrusive/jquery.validate.unobtrusive.js Removed bundled third-party JS from legacy sample
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/wwwroot/lib/jquery-validation-unobtrusive/LICENSE.txt Removed third-party license file
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/wwwroot/lib/bootstrap/LICENSE Removed Bootstrap license file
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/wwwroot/js/site.js Removed legacy sample static JS
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/wwwroot/css/site.css Removed legacy sample static CSS
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/appsettings.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/appsettings.Development.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Services/Service1.cs Removed legacy disposable services sample
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Program.cs Removed legacy service lifetime registration sample
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/_ViewStart.cshtml Removed legacy Razor Pages layout setup
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/_ViewImports.cshtml Removed legacy Razor Pages imports
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Shared/_ValidationScriptsPartial.cshtml Removed legacy validation script partial
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Shared/_Layout.cshtml Removed legacy Razor Pages layout
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Privacy.cshtml.cs Removed legacy Razor Page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Privacy.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Index2.cshtml.cs Removed legacy test page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Index2.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Index.cshtml.cs Removed legacy services usage sample
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Index.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Error.cshtml.cs Removed legacy error page model
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/Pages/Error.cshtml Removed legacy error page
aspnetcore/fundamentals/dependency-injection/samples/6.x/DIsample2/DIsample2/DIsample2.csproj Removed legacy sample project
aspnetcore/fundamentals/dependency-injection/samples/6.x/AntiPattern3/Program.cs Removed legacy anti-pattern sample entrypoint
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/appsettings.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/appsettings.Development.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/StartupMyDependency2.cs Removed legacy Startup-based DI sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/StartupMyDependency.cs Removed legacy Startup-based DI sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/StartupMain.cs Removed legacy Startup sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/StartupEF.cs Removed legacy EF Startup sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Startup5.cs Removed legacy ServiceDescriptor sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Startup2.cs Removed legacy lifetimes Startup sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Startup.cs Removed legacy Startup sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Services/OperationService.cs Removed legacy operation service
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Services/MyDependency.cs Removed legacy services
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Program.cs Removed legacy Program sample (conditional compilation)
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/_ViewStart.cshtml Removed legacy Razor Pages layout setup
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/_ViewImports.cshtml Removed legacy Razor Pages imports
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Shared/_Layout.cshtml Removed legacy layout with inline CSS
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index5.cshtml.cs Removed legacy DI usage page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index5.cshtml Removed legacy DI usage page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index4.cshtml.cs Removed legacy operations page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index4.cshtml Removed legacy operations page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index2.cshtml.cs Removed legacy DI usage page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index2.cshtml Removed legacy DI usage page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index.cshtml.cs Removed legacy lifetime logging page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Index.cshtml Removed legacy lifetime logging page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Error.cshtml.cs Removed legacy error page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/Error.cshtml Removed legacy error page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/About.cshtml.cs Removed legacy logging page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Pages/About.cshtml Removed legacy page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Models/Operation.cs Removed legacy operation implementation
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Middleware/MyMiddleware.cs Removed legacy middleware sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Interfaces/IOperation.cs Removed legacy operations interfaces
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/Interfaces/IMyDependency.cs Removed legacy DI interface
aspnetcore/fundamentals/dependency-injection/samples/3.x/DependencyInjectionSample/DependencyInjectionSample.csproj Removed legacy sample project
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/wwwroot/lib/jquery/LICENSE.txt Removed jQuery license file from legacy sample assets
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/wwwroot/lib/jquery-validation/LICENSE.md Removed jQuery Validation license file
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/wwwroot/lib/jquery-validation-unobtrusive/jquery.validate.unobtrusive.js Removed bundled third-party JS from legacy sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/wwwroot/lib/jquery-validation-unobtrusive/LICENSE.txt Removed third-party license file
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/wwwroot/lib/bootstrap/LICENSE Removed Bootstrap license file
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/wwwroot/js/site.js Removed legacy sample static JS
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/wwwroot/css/site.css Removed legacy sample static CSS
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/appsettings.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/appsettings.Development.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Startup2.cs Removed legacy Startup sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Startup.cs Removed legacy Startup sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Services/Service1.cs Removed legacy disposable services sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Program.cs Removed legacy Program sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/_ViewStart.cshtml Removed legacy Razor Pages layout setup
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/_ViewImports.cshtml Removed legacy Razor Pages imports
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Shared/_ValidationScriptsPartial.cshtml Removed legacy validation script partial
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Shared/_Layout.cshtml Removed legacy Razor Pages layout
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Privacy.cshtml.cs Removed legacy privacy page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Privacy.cshtml Removed legacy privacy page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Index2.cshtml.cs Removed legacy test page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Index2.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Index.cshtml.cs Removed legacy services usage sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Index.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Error.cshtml.cs Removed legacy error page model
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/Pages/Error.cshtml Removed legacy error page
aspnetcore/fundamentals/dependency-injection/samples/3.x/DIsample2/DIsample2/DIsample2.csproj Removed legacy sample project
aspnetcore/fundamentals/dependency-injection/samples/3.x/AntiPattern3/Startup2.cs Removed legacy anti-pattern Startup sample
aspnetcore/fundamentals/dependency-injection/samples/3.x/AntiPattern3/Startup.cs Removed legacy anti-pattern Startup sample
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/appsettings.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/appsettings.Development.json Removed legacy sample configuration
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Startup.cs Removed legacy MVC 2.2 sample Startup
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Services/OperationService.cs Removed legacy operation service
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Services/MyDependency.cs Removed legacy async logging dependency
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/README.md Removed legacy sample README
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Program.cs Removed legacy Program
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Pages/_ViewStart.cshtml Removed legacy Razor Pages layout setup
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Pages/_ViewImports.cshtml Removed legacy Razor Pages imports
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Pages/Shared/_Layout.cshtml Removed legacy layout with inline CSS
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Pages/Index.cshtml.cs Removed legacy Razor Page model
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Pages/Index.cshtml Removed legacy Razor Page
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Pages/Error.cshtml.cs Removed legacy error page model
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Pages/Error.cshtml Removed legacy error page
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Models/Operation.cs Removed legacy operation implementation
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Interfaces/IOperation.cs Removed legacy operations interfaces
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/Interfaces/IMyDependency.cs Removed legacy DI interface
aspnetcore/fundamentals/dependency-injection/samples/2.x/DependencyInjectionSample/DependencyInjectionSample.csproj Removed legacy sample project
aspnetcore/fundamentals/dependency-injection/includes/dependency-injection-8.md Removed prior monikered DI include (8.0)
aspnetcore/fundamentals/dependency-injection/includes/dependency-injection-5-7.md Removed prior monikered DI include (5.0–7.0)
Comments suppressed due to low confidence (3)

aspnetcore/fundamentals/dependency-injection/samples/6.x/DIwebApp/wwwroot/lib/jquery/LICENSE.txt:1

  • This removes the license file for a third-party asset location (wwwroot/lib/jquery). If any third-party library files remain in the repo after this PR (for example jquery.js, bootstrap.*, jquery.validate*), removing the corresponding LICENSE files can create a compliance issue. Either delete the entire third-party library directories along with their licenses, or keep the LICENSE files (or move licensing info to a centralized NOTICE/THIRD-PARTY file used by this repo).
    aspnetcore/fundamentals/dependency-injection/includes/dependency-injection-8.md:1
  • This include file is deleted in full. If it is still referenced anywhere via [!INCLUDE[](...)] (or equivalent build-time include), the docs build will fail with a missing-include error. Before merging, do a repo-wide search for includes/dependency-injection-8.md and ensure all references are removed or updated to the new content location.
    aspnetcore/fundamentals/dependency-injection/includes/dependency-injection-5-7.md:1
  • Same issue as the 8.0 include: deleting this file will break any remaining includes (monikered or otherwise) that pull it in. A repo-wide search for includes/dependency-injection-5-7.md should be part of the PR to ensure there are no dangling references.

@guardrex guardrex requested a review from tdykstra March 3, 2026 17:59
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.

Update "Dependency injection in ASP.NET Core" to use Blazor & Minimal APIs for examples

2 participants