import ngModule from '../module'; class ItemData { constructor($scope, $timeout) { this.$scope = $scope; this.$timeout = $timeout; } $onChanges(data) { if (!this.$scope.watcher) this.$timeout(() => { this.$scope.watcher.data = data.item.currentValue; }); } } ItemData.$inject = ['$scope', '$timeout']; ngModule.component('vnItemData', { template: require('./item-data.html'), bindings: { item: '<' }, controller: ItemData });