I am trying to edit bus list in browser console for this bus search angualrjs site.
I tried to access the filteredBusData(ng-repeat) list in that page which is used in ng-repeat from console.
Code:
Method 1:
angular.element(document.body).injector().invoke(function ($rootScope)
{
scope = $rootScope;
console.log(scope.filteredBusData);
});
Method 2:
angular.element('[ng-controller="busTicketCheckoutCtrl"]').scope;
`busTicketCheckoutCtrl` is the particular controller
Problem:
Both the methods didn't work :(
Method 1: scope.filteredBusData is undefined
Method 2: Uncaught Error: [jqLite:nosel] Looking up elements via selectors is not supported by jqLite!
Question:
How to access the particular controller scope in the browser console?
Any suggestion/idea will be grateful.