Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
GitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
"foreach" binding doesn't work with arrays of primitives #3
At the moment, it is not possible to use a "foreach" binding in a template if it iterates over an array (or ObservableList) that is not an object (such as an array of strings or numbers).
This happens because of how we create a new context (by creating a new object whose prototype is the original data). At that point, we need to verify that what we received actually is an object and create one if it isn't.
<ul bind=" foreach: component.values "> <template> <li><span bind="text: $item"></span></li> </template> </ul>
The above example doesn't work if the
This issue should be fixed in