         when 33 then move(-11)
 
     $scope.$watch 'search', search
+    $scope.$watch 'limit', -> search('')
 
     $scope.$watch 'active', (value) ->
       window.setTimeout((()-> scrollIfNeeded(getActiveIndex())) , 0) if value

      attrs.$observe 'required', (value) ->
        scope.required = value

      scope.$watch  'selectedItem', ->
        childScope = scope.$new()
        childScope.item = scope.selectedItem
        transcludeFn childScope, (clone) ->

        ul.scrollTop -= viewport.top - item.top

    search = (q) ->
      $scope.shownItems = filter(q, $scope.items, $scope.valueAttr).slice(0, $scope.limit)
      $scope.activeItem = $scope.shownItems[0]

    $scope.selection = (item)->
      $scope.selectedItem = item
