I have a web api project "Reactivities" and another project "Persisitence" to place my DbContext. When I try to use my add-migration in the Reactivities, using this syntax in the console add-migration InitalCreate -Context .\Persistence I get this error:
No DbContext named '.\Persistence' was found.
Even if I use add-migration InitialCreate -Context .\Persistence\DataContext still I get the same error,
This is in my startup class in Reactivities
services.AddDbContext<DataContext>(opt =>
{
opt.UseSqlite(Configuration.GetConnectionString("DefaultConnection"));
});
How can I correct this?