Clicking on a genre brings up a list of movies within that genre.Clicking the Edit button next to an entry lets you change that entry.You’ll see this in action when I discuss data binding later.In a pure SPA, all UI interaction occurs on the client side, through Java Script and CSS.For example, you might write a native mobile client that consumes the service. I won’t go into detail about Web API here—you can read more at asp.net/web-api.First, I created a Movie class that represents a movie.
SPAs use AJAX and HTML5 to create fluid and responsive Web apps, without constant page reloads.
You could replace the entire back end that runs the service, and as long as you don’t change the API, you won’t break the client. NET Web API to the project by checking Web API under “Add folders and core references for:” as shown in Figure 3. NET Project in Visual Studio 2013 The new project has all the libraries needed for Web API, plus some Web API configuration code. I didn’t use the template in my app because I wanted to show a simpler example starting from scratch.
The reverse is also true—you can replace the entire client app without changing the service layer. The SPA template is a great resource, though, especially if you want to add authentication to your app. NET Web API to create a simple REST API for the app.
I also checked “Use async controller actions” to take advantage of the new async feature in EF 6.
I selected the Movie class for the model and selected “New data context” to create a new EF data context.