function prelink($scope, $element, $attr, navViewCtrl) {
        var clone, sc, scrollView, scrollCtrl;

        $scope.$watch(function() {
          return ($scope.$hasHeader ? ' has-header' : '')  +
            ($scope.$hasSubheader ? ' has-subheader' : '') +
            ($scope.$hasFooter ? ' has-footer' : '') +
            ($scope.$hasSubfooter ? ' has-subfooter' : '') +
            ($scope.$hasTabs ? ' has-tabs' : '') +
            ($scope.$hasTabsTop ? ' has-tabs-top' : '');
        }, function(className, oldClassName) {
          $element.removeClass(oldClassName);
          $element.addClass(className);
        });

        $ionicBind($scope, $attr, {
          $onScroll: '&onScroll',
          $onScrollComplete: '&onScrollComplete',
          hasBouncing: '@',
          scroll: '@',
          padding: '@',
          hasScrollX: '@',
          hasScrollY: '@',
          scrollbarX: '@',
          scrollbarY: '@',
          startX: '@',
          startY: '@',
          scrollEventInterval: '@'
        });

        if (angular.isDefined($attr.padding)) {
          $scope.$watch($attr.padding, function(newVal) {
            innerElement.toggleClass('padding', !!newVal);
          });
        }

        if ($scope.scroll === "false") {
          //do nothing
        } else if(attr.overflowScroll === "true") {
          $element.addClass('overflow-scroll');
        } else {

          scrollCtrl = $controller('$ionicScroll', {
            $scope: $scope,
            scrollViewOptions: {
              el: $element[0],
              delegateHandle: attr.delegateHandle,
              bouncing: $scope.$eval($scope.hasBouncing),
              startX: $scope.$eval($scope.startX) || 0,
              startY: $scope.$eval($scope.startY) || 0,
              scrollbarX: $scope.$eval($scope.scrollbarX) !== false,
              scrollbarY: $scope.$eval($scope.scrollbarY) !== false,
              scrollingX: $scope.$eval($scope.hasScrollX) === true,
              scrollingY: $scope.$eval($scope.hasScrollY) !== false,
              scrollEventInterval: parseInt($scope.scrollEventInterval, 10) || 20,
              scrollingComplete: function() {
                $scope.$onScrollComplete({
                  scrollTop: this.__scrollTop,
                  scrollLeft: this.__scrollLeft
                });
              }
            }
          });
          //Publish scrollView to parent so children can access it
          scrollView = scrollCtrl.scrollView;
        }

      }
@ngdoc directive
@name ionContent
@module ionic
@restrict E

@description
The ionContent directive provides an easy to use content area that can be configured
to use Ionic's custom Scroll View, or the built in overflow scorlling of the browser.

While we recommend using the custom Scroll features in Ionic in most cases, sometimes
(for performance reasons) only the browser's native overflow scrolling will suffice,
and so we've made it easy to toggle between the Ionic scroll implementation and
overflow scrolling.

You can implement pull-to-refresh with the {@link ionic.directive:ionRefresher}
directive, and infinite scrolling with the {@link ionic.directive:ionInfiniteScroll}
directive.

@param {string=} delegate-handle The handle used to identify this scrollView
with {@link ionic.service:$ionicScrollDelegate}.
@param {boolean=} padding Whether to add padding to the content.
of the content.  Defaults to true on iOS, false on Android.
@param {boolean=} scroll Whether to allow scrolling of content.  Defaults to true.
@param {boolean=} overflow-scroll Whether to use overflow-scrolling instead of
Ionic scroll.
@param {boolean=} has-bouncing Whether to allow scrolling to bounce past the edges
of the content.  Defaults to true on iOS, false on Android.
@param {expression=} on-scroll Expression to evaluate when the content is scrolled.
@param {expression=} on-scroll-complete Expression to evaluate when a scroll action completes.