C
C#15mo ago
octalide

✅ New to Blazor and EF. Need some tips.

I'm trying to set up a site that will have dozens of db models. I don't want to manually create CRUD pages for each model if possible, but I'm brand new to both Blazor and EF. I'm currently lost in documentation hell and can't seem to find a good way to use automatic routing to generate CRUD pages for my models. Any suggestions, links, or code samples would be incredibly helpful.
4 Replies
Messiah
Messiah15mo ago
octalide
octalideOP15mo ago
I'm unfortunately using VS Code and don't have the option to scaffold. That also would result in about... 160 different files for CRUD...
Hercules
Hercules15mo ago
dotnet ef dbcontext scaffold "<your existing db connection string>" Microsoft.EntityFrameworkCore.SqlServer -o Models make sure you have Microsoft.EntityFrameworkCore.Tools.DotNet (2.0.3 or latest) in your project.
Accord
Accord15mo ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
Want results from more Discord servers?
Add your server