title: AngularJS - view not updating after scope change
body: <p>I am working with some data via Firebase, and for some reason when the value changes on the server, the scope is getting updated in my console, however the angular view is not updating.</p>
  
  <p>I've tried some different approaches including wrapping the reference to the scope in a <code>$timeout</code> &amp; <code>$apply</code>, but still no solution. I've worked with angular many times and I've never ran into this behavior before. There's only one controller in the app.</p>
  
  <p><em>js</em></p>
  
  <pre><code>app.controller('someCtrl', function($scope, $timeout){
  
      $scope.publishedItems =[];
      var fbRef = firebase.database().ref('stories/' + storyId + "/correspondents").orderByChild('published').equalTo(true);
      fbRef.on('value', function(snapshot) {
      //update scope
  
      $scope.publishedItems = snapshot.val();
  
      console.log($scope.publishedItems)// this logs the correct data, however the markup is not changing
  
  });
  </code></pre>
  
  <p><em>html</em></p>
  
  <pre><code> &lt;div ng-controller="someCtrl"&gt;
        &lt;div ng-repeat="item in publishedItems"&gt;
          {{item}}
        &lt;/div&gt;
   &lt;/doc&gt;
  </code></pre>
  
  <p><strong>resolved</strong></p>
  
  <p>So after some debugging, it turned out I had a function running outside of the Angular app that was appending some markup to the dom which was interfering with Angulars digest cycle.</p>
  
  <p>Working as expected now</p>