Open danroth27 opened 7 months ago
addressed #2835, will be released for .NET 8 and .NET 9 Preview 6 next week!
Just wanted to send some love here! ❤️
I'm working on a new Pluralsight course called "Building a Data-driven Blazor Server Application with EF Core" and while recording the demo of the scaffolder I just noticed that the generated code is using IDbContextFactory. That's fantastic! Thank you everyone!
I guess this issue can be closed.
We've received feedback from users that the component code generated by the Blazor CRUD scaffolder should use the
IDbContextFactory
instead of injecting theDbContext
directly to avoid making multiple overlapping queries with the sameDbContext
instance. With static server-side rendering this is less likely to happen, but we think it's best to make the change to be in line with our documented Blazor guidance.