title: knockout foreach computed value
body: <p>I am trying to add a computed value to my viewModel object. And I am using foreach to create a table of rows. I am not able to get around this computed function.</p>
  
  <p>I am trying to do this.</p>
  
  <pre><code>viewModel =
   {
     objectName: ko.observable([
         { value: "", triggerValue: "0"},
         { value: "", triggerValue: "1"},
         { value: "", triggerValue: "1"} 
     ]),
   };
  
  viewModel.objectName().value= ko.computed(function() {
        return this.objectName().triggerValue= "0" ? "Apple" : "Microsoft";
      }, this);
  </code></pre>
  
  <p>I want the viewModel objectName output to look like </p>
  
  <pre><code>{value: "Apple", triggerValue: "0"},
  {value: "Microsoft", triggerValue: "1"},
  {value: "Microsoft", triggerValue: "1"}
  </code></pre>
  
  <p>Thanks.
  KDK</p>