I am writing a browser app, and I have a file that creates an object and initializes it. The app is written in AngularJS, but the file in question is plain Javascript, outside the Angular ecosystem.
I want to use promises in that file, but since Angular contains an an implementation of Q, I'd rather just use that than bring in another library.
I am also using RequireJS.
So, is there a way to use $q in a non-Angular file?