Category: Knockout
-
Understanding click binding in Knockout.js
Click Binding adds click event to element on View. You can do click binding with any function in ViewModel or you can bind to any normal function. Let us try to understand it with a very simple ViewModel. We have a ViewModel as below As you see there is one function as property of ViewModel…
-
Control Flow bindings in Knockout.js
You can control flow of element on the view using Control Flow bindings of Knockout.js. There are four Control Flow bindings foreach binding if binding ifnot binding with binding Out of these four bindings foreach and if bindings are used very often. foreach binding foreach binding repeat same markup for number of times equivalent to…
-
Computed Observable in Knockout.js
In this post we will take a look on Computed Observable in Knockout.js. Let us start with an example, you have a ViewModel Now you want a custom message to be rendered on the view, that message will depend on other observable of ViewModel. To create that custom message you need to create a Computed…
-
Video : What is Chained Syntax in Knockout.js
In this video you will learn about Chained Syntax in Knockout.js We use Chained Syntax to update more than one property of ViewModel in one line of code.
-
Why we need Observable Properties in Knockout.js
In this post we will take a look on why we need observable properties in Knockout.js Before you read further this blog post, I would recommend you to read Setting up Visual Studio for Knockoutjs Development Create your First MVVM based JavaScript App in two simple steps using Knockoutjs Inbuilt Bindings in Knockout.js: Controlling Text…
-
Inbuilt Bindings in Knockout.js: Controlling Text and Appearance
Setting up Visual Studio 2013 for Knockoutjs Development Create your First MVVM based JavaScript App in two simple steps using Knockoutjs In simpler terms we can define Knockoutjs binding as a mechanism to establish relationship between view and ViewModel. View takes user action and pass the instruction to ViewModel. One of the most popular example…
-
Can you answer these 10 basic Knockout Questions?
Q1. KO performs following operations Automatic Refresh Two way Binding Templating All of the above Q2. On which event bindings in KO fire notification Change event Update event On Any event None of the above Q3. Value of computed observable is determined at Time of creation Time of update Time of…
-
Create your First MVVM based JavaScript App in two simple steps using Knockoutjs
Read all Knockoutjs posts here Setting up Visual Studio 2013 for Knockoutjs Development Okay purpose of this post is very simple to explain you why Knockoutjs. I will try to put it in simplest way that Why we need to work Knockoutjs. If you are not a begineer then probably this post may appear very…
-
Working with Knockout.js Part 6: Working with text binding
Working with Knockout.js Part 5: Working with visible binding Working with Knockout.js Part 4: Observable Arrays Working with Knockout.js Part 3: Working with Observables Working with Knockout.js part 2: Understanding MVVM Working with Knockout.js Part 1: Getting started with Knockoutjs In last post we started learning about bindings. We had a look on visible binding…
-
Working with Knockout.js Part 5: Working with visible Binding
Working with Knockout.js Part 4: Observable Arrays Working with Knockout.js Part 3: Working with Observables Working with Knockout.js part 2: Understanding MVVM Getting started with Knockout.js So far we have learnt about different aspects of ViewModel creation in Knockout.js. We learnt and discussed about MVVM, Observable, and Observable Array etc. In this post we will…