Get current view's custom attribute


#1
<ion-content class="appcontent" scroll="false" has-back-button="false">

How to get the current view ion-content “has-back-button” boolean value? I had tried the following but I keep getting the cached pages ion-content tags boolean value.

  1. var currentView = document.querySelector(‘ion-view[nav-view=“active”]’);
    var selectEl = currentView.querySelector(“ion-content”)[0];

  2. $ionicHistory.currentView()
    var x=document.getElementsByTagName(“ion-content”)[0].getAttribute(“has-back-button”);

Help is appreciated :slight_smile: