Set initial zoom for ion-scroll

Is there a way to do this? Set a default Scale value.

2 Likes

In the controller:

  var initZoom=0.7;
  $scope.$on('$ionicView.enter',function(){
    $ionicScrollDelegate.$getByHandle('wavesScroller').zoomBy(initZoom);
  });

In the view:

<ion-scroll direction="xy" zooming="true" ng-style="style()" delegate-handle="wavesScroller">

@tomchiverton where is the controller file? Sorry i’m new with ionic!

If you are using routes/states, it’s declared alongside the view name.