Closed Nel75 closed 9 years ago
You are correct. Modules must either be declared in the file that you want Intellisense in, or else declared as properties of the window object. I thought about recursively searching the window object hierarchy for modules but this seemed far too intensive.
Readme updated.
Yeah, I agree. Thanks!
On Oct 13, 2014, at 11:57 AM, John Bledsoe notifications@github.com wrote:
You are correct. Modules must either be declared in the file that you want Intellisense in, or else declared as properties of the window object. I thought about recursively searching the window object hierarchy for modules but this seemed far too intensive.
— Reply to this email directly or view it on GitHub.
Thank you so much for this awesome module!! Couldn't find anything else out there like it. Makes coding Angular in VS a lot easier and much more fun. I just had some trouble getting it to work since I was saving my angular module to an object to emulate namespacing rather than to the global scope which this module requires as shown in snippet below. So thought maybe just a mention of that requirement in the readme might help someone else.
// Search the window object for globally-defined angular modules, and track them if they are found. if (window) { forEach(window, function (obj) { if (isAngularModule(obj)) { trackModule(obj); } }); }