Adam--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To view this discussion on the web visit https://groups.google.com/d/msg/angular/-/_5z5drd-NukJ.
To post to this group, send email to ang...@googlegroups.com.
To unsubscribe from this group, send email to angular+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/angular?hl=en.
In this fiddle the $location service is passed straight through to the scope. Personally, I would use the controller to give a layer of abstraction between the view and the service by creating a method like your url() method.
Pete
On 9 April 2012 12:08, Adam Wynne <adam...@gmail.com> wrote:
Hi guysI'd like to be able to access my services in the view (so if I've written a service called 'auth', I could use something like ng-show="auth.loggedIn"this (broken) fiddle demonstrates what I'd like to do:Any help appreciatedThanks
Adam--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To view this discussion on the web visit https://groups.google.com/d/msg/angular/-/_5z5drd-NukJ.
To post to this group, send email to ang...@googlegroups.com.
To unsubscribe from this group, send email to angular+unsubscribe@googlegroups.com.