myApp.directive('superPuper', function() {
return {
restrict: 'E',
replace: true,
link: function($scope, element, attrs) {
var val = $scope.x;
if(val !== 3) {
//Ничего не выводим!!!
var li = angular.element('<li>');
li[0].textContent = val;
element.append(li);
}
}
}
})