Howdy people. I'm looking to build a large lib-like-object that once instantiated, has 'state' (i.e., once initialized, use that single object in all of the app). It's intentionally written as a standalone js object to be used feasibly in other projects. I'm also looking into using angularjs for my new site, and wondering what the correct protocol for bringing this resource into my site is. I have a feeling binding an instantiation of the lib/object into my rootScope is frowned upon? What's the 'angular way'? Every controller will use it. It seems like making a service of it is essentially re-writing it into angular form, which seems a little wasteful. I've also read that angular services are to be stateless, thus those don't doesn't seem like my solution. Perhaps I load it into the 'module' somehow? Not sure. What questions must I answer to help you help me!? :)
FYI, for context, the lib is targeted to manage data between datastores--indexedDB if the host is unreachable and my server if it itself is reachable--and to help facilitate my app run smoothly while offline. Thanks! -- You received this message because you are subscribed to the Google Groups "AngularJS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/angular. For more options, visit https://groups.google.com/d/optout.
