concatenating a string to $index in foreach loop knockoutjs
<p>This is a connected to the answer to <a href="https://stackoverflow.com/questions/28488524/ko-js-dynamically-generated-radio-buttons-and-checked-dependent-computations">this question</a></p>

<p>The following works..<a href="http://jsfiddle.net/vt6v6L9u/2/" rel="nofollow noreferrer">http://jsfiddle.net/vt6v6L9u/2/</a></p>

<pre><code>&lt;div data-bind="foreach: retrievedUsers" &gt;
    &lt;div&gt;
        &lt;label data-bind="attr:{for:$index}"&gt;
</code></pre>

<p>I need to concatenate a string to $index.. <a href="http://jsfiddle.net/vt6v6L9u/4/" rel="nofollow noreferrer">http://jsfiddle.net/vt6v6L9u/4/</a></p>

<pre><code>&lt;div data-bind="foreach: retrievedUsers" &gt;
    &lt;div&gt;
        &lt;label data-bind="attr:{for:'const' + $index}"&gt;
</code></pre>

<p>The fiddle seems to work but if you inspect the radio button element..
you find..</p>

<pre><code>&lt;label data-bind="attr:{for:'const' + $index}" for="constfunction c(){if(0&lt;arguments.length)return c.equalityComparer&amp;amp;&amp;amp;c.equalityComparer(d,arguments[0])||(c.O(),d=arguments[0],c.N()),this;a.i.lb(c);return d}"&gt;
</code></pre>

<p>Any help is sincerely appreciated</p>

<p>Thanks</p>