In the previous section, we put the data directly inside the View Model; this was just to show how the ViewModel works. In any normal application the source of your data is online and you get it by calling a remote service.
jQuery to deal with our AJAX request in the rest of the book.
When you develop a big application to be used online you have to decide which browser you're going to support; the main reason is that each browser you decide to support means:
Testing on it
Checking if your code/style sheet/HTML page can be supported, and how
For this reason, many big companies keep an eye on the browser market share data; it helps you to decide if it's time to drop support for a particular browser.
I mentioned this here because we are going to use jQuery. This library is different from KnockoutJS, because you must choose between two branches: 1.x and 2.x.
The main difference here is the compatibility; if you want to support all the browsers KnockoutJS supports you have to download the 1.x branch, otherwise you can choose 2.x.
For these chapters, we will use the 1.x branch (we will use 1.11.1). You can download the latest jQuery library here: http://code.jquery.com/jquery-1.11.1.min.js.
After you download it, save it as
Then update the index page to include it before the row where we included KnockoutJS: