Asp.Net MVC 5

30
Le novità di ASP.NET MVC 5 Emanuele Bartolesi Senior SharePoint Consultant [email protected] @kasuken

description

 

Transcript of Asp.Net MVC 5

Page 1: Asp.Net MVC 5

Le novità di ASP.NET MVC 5

Emanuele BartolesiSenior SharePoint Consultant [email protected]@kasuken

Page 2: Asp.Net MVC 5

#WebAndBeyond

Page 3: Asp.Net MVC 5

Sponsor

Page 4: Asp.Net MVC 5

Agenda Chi eravamo e dove andiamo One Asp.Net Novità WebForms Novità MVC 5 Migrazione da MVC 4 a MVC 5

Page 5: Asp.Net MVC 5

Prima…

Page 6: Asp.Net MVC 5
Page 7: Asp.Net MVC 5
Page 8: Asp.Net MVC 5

Adesso…

Page 9: Asp.Net MVC 5

ONE ASP.NET

Page 10: Asp.Net MVC 5
Page 11: Asp.Net MVC 5
Page 12: Asp.Net MVC 5

ONE ASP.NET

ASP.NET

WebForms

Sites

WebPages

SinglePageApps

MVCWebAPI

SignalR

Services

YOU! YOU!

Page 13: Asp.Net MVC 5

ASP.NET 4.5In generale• Script e Librerie da NuGet• Async• Web Optimization• Request Validation• Data Annotations• HTML5 Web Sockets (IIS 8 e SignalR)• 30% più veloce a partire• 30% di occupazione di memoria in meno!

Page 14: Asp.Net MVC 5

WebForms

Page 15: Asp.Net MVC 5

WebForms• HTML5• Request Validation• Strongly Typed Data Controls• Model Binders

Page 16: Asp.Net MVC 5

Strongly Typed Data Controls

Page 17: Asp.Net MVC 5

MVC 5

Page 18: Asp.Net MVC 5

MVC 5 • HTML5• Bootstrap• Scaffolding• Async• Routing• ASP.NET Identity• Filter Overrides• EF6

Page 19: Asp.Net MVC 5

demo

Bootstrap

Page 20: Asp.Net MVC 5

demo

Scaffolding

Page 21: Asp.Net MVC 5

demo

Routing

Page 22: Asp.Net MVC 5

demo

ASP.NET Identity

Page 23: Asp.Net MVC 5

demo

Filter Overrides

Page 24: Asp.Net MVC 5

E se ho già un progetto MVC 4?

Page 25: Asp.Net MVC 5

MVC 4 > MVC 5• Verificare che le librerie usate siano

compatibili• Tools -> Library Package Manager ->

Package Manager Console• Uninstall-Package -Id

Microsoft.AspNet.WebPages.Administration• Uninstall-Package -Id Microsoft-Web-Helpers• Uninstall-Package -Id Microsoft.AspNet.Mvc.FixedDisplayModes• Update-Package (aggiorna tutti i pacchetti scaricati)

Page 26: Asp.Net MVC 5

MVC 4 > MVC 5• Aggiornare il web.config

Page 27: Asp.Net MVC 5

MVC 4 > MVC 5• Aggiornare il web.config nella cartella

Views• Tools -> Library Package Manager ->

Package Manager Console• Install-Package -Id 

Microsoft.AspNet.WebHelpers• Unload Project -> Edit ProjectName.csproj

e rimuovere il Guid dell’elemento «ProjectTypeGuids»

Page 28: Asp.Net MVC 5

#WebAndBeyond

Page 29: Asp.Net MVC 5

Grazie

Page 30: Asp.Net MVC 5

© 2011 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted

to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.