angularjs - Once I turn off debuggingData in angular, is there another way to get the rootscope? -


i think having debugging info on default in angular sink large apps. can disable in production:

https://docs.angularjs.org/guide/production#disabling-debug-data

but there cases do:

angular.element(document).scope()

in order access rootscope. there way in angular $rootscope without debugging feature on?

to access $rootscope

angular.element(document).injector().get('$rootscope') 

Comments

Popular posts from this blog

javascript - gulp-nodemon - nodejs restart after file change - Error: listen EADDRINUSE events.js:85 -

Fatal Python error: Py_Initialize: unable to load the file system codec. ImportError: No module named 'encodings' -

javascript - oscilloscope of speaker input stops rendering after a few seconds -