Skip to content

Instantly share code, notes, and snippets.

View bertrandg's full-sized avatar
:octocat:
 

bertrandg bertrandg

:octocat:
 
  • Lyon, FRANCE
View GitHub Profile
.ng-scope {
outline: 1px solid blue;
}
var debugWatchers = function(selector, showExp) {
var target, i, checkInsideFn, jq, items,
nb_watchers = 0,
nb_scopes = 0,
scopes_id = {};
if(typeof jQuery == 'undefined') {
jq = document.createElement('script');
jq.type = 'text/javascript';
jq.src = '//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js';
(function () {
var i, data, scope,
count = 0,
all = document.all,
len = all.length,
test = {};
for (i=0; i < len; i++) {
data = angular.element(all[i]).data();
if (data.hasOwnProperty('$scope') && data.$scope.$$watchers) {