Let's create an application based on a very simple model. It will contain only two properties:
LastName. The View will contain two
TextBox elements to edit properties and a
span element with a greeting text. You can find the full code of the example in the supplement code bundle of this book (
HomeLibrary/HelloWorld) or look for the live example on the official site (http://knockoutmvc.com/HelloWorld).
Let's create a new ASP.NET MVC 4 project and install the kMVC packages via NuGet.
First of all, we should create a model. We will work with a very simple example. Let's define the following model (
using System.Web.Script.Serialization; ...