title: Angular 1.5 - how to bind an attribute with a $rootScope variable in a component?
body: <p>I have 2 angular components : app-menu which use app-menuitem without transclude.</p>
  
  <p>In index.html</p>
  
  <pre><code>&lt;app-menu items="menuitems" &gt;&lt;/app-menu&gt;
  </code></pre>
  
  <p>In app-menu.html</p>
  
  <pre><code>&lt;app-menuitem label="{{ item.label }}" isdisabled="item.isdisabled" &gt;&lt;/app-menuitem&gt;
  </code></pre>
  
  <p>In app-menuitem.html</p>
  
  <pre><code>&lt;button data-ng-disabled="$ctrl.isdisabled"&gt;{{ $ctrl.label }}&lt;/button&gt;
  </code></pre>
  
  <p>I would like to bind the attribute 'isdisabled' with a $rootScope variable in my controller like :</p>
  
  <pre><code>$scope.menuitems = [{label:"myButton", isdisabled: $rootScope.fooIsLoaded}, ...]
  </code></pre>
  
  <p>I manage to initialize it but not to bind it in order to refresh each time the $rootScope.fooIsLoaded value is changed which is the angular logic. Someone as an idea ?</p>