Problem databinding markers to Each on MapView

Fuse, preview on iOS and Android. Was broken somewhere between 0.10 and 0.11. @sunjammer says it’s related to the Each implementation.

Consider the following UX:

<App Theme="Basic" Background="#333333ff">

    var Observable = require("FuseJS/Observable");
    var markers = Observable();

    function Marker(latitude, longitude, label) {
        this.latitude = latitude;
        this.longitude = longitude;
        this.label = label;

    function generate_markers() {
        for (var i = 0; i < 3; i++) {
            var lat = Math.floor((Math.random() * 60) + 1);
            var lng = Math.floor((Math.random() * 90) + 1);
            var name = "test marker at " + lat + " / " + lng;
            var marker = new Marker(lat, lng, name);
        console.log("The markers are now: " + JSON.stringify(markers));

    function marker_click(args) {
        console.log('Marker tapped: ' + JSON.stringify(args.label));

    module.exports = {
        markers: markers,
        marker_click: marker_click,
        generate_markers: generate_markers

        <Panel Alignment="TopCenter">
            <Button Text="Generate markers">
                <Clicked Handler="{generate_markers}" />
        <NativeViewHost Margin="0,60,0,0">
            <MapView Latitude="56.9489" Longitude="24.1064" Zoom="20000000" Style="Hybrid" MarkerTapped="{marker_click}">
                <Each Items="{markers}">
                    <MapMarker Latitude="{latitude}" Longitude="{longitude}" Label="{label}" />


and .unoproj:

  "Packages": [
  "Includes": [
  "Android": {
    "Geo": {
      "ApiKey": "removed-my-api-key-use-your-own"

When launching the app, it initially generates 3 markers in the Observable that is databound to the Each under MapView, and is used to put the markers on the map.

However, the first 3 markers appear to have their latitude/longitude/label set to null (as you can see in console log when clicking on them), and they are grouped at 0/0 positions on the map (you can tell by the dark drop shadow).

If I then click the “Generate” button on top, the new markers appear on the map correctly. The original 3 markers still stay at 0/0. A click on one of the new markers shows a correct label in the console log.

Thanks for the test case, I’m on it :slight_smile:

Bug found and squashed <3