February 2018
Intermediate to advanced
668 pages
15h 18m
English
"MediatR.Extensions.Microsoft.DependencyInjection": "4.0.0"
We will also need the AutoMapper package to map Business models to ViewModels. We will talk about AutoMapper in more detail in Chapter 13, Views, Models, and ViewModels:
"AutoMapper.Extensions.Microsoft.DependencyInjection": "3.2.0"
public class Startup{ public void ConfigureServices(IServiceCollection services) { var connection = @"Data Source=MyServer;Initial Catalog=CookBook;Integrated Security=True"; services.AddDbContext<CookBookContext>( options => options.UseSqlServer(connection)); services.AddMvc(); ...