knockout dynamically bind image src based on boolean value Edit
In my asp .net mvc application in the razor view I want to bind img src attribute based on weather IsFavourite is true of false. I am setting up the initial value of observable isFavourite by setting the value from asp .net mvc model @(@Model.IsFavourite == true ? "true" : "false"). Check the code below how this can be done.