Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

docs($location): confusing terminology (observers) #7497

Closed
wants to merge 1 commit into from
Closed

docs($location): confusing terminology (observers) #7497

wants to merge 1 commit into from

Conversation

thorn0
Copy link
Contributor

@thorn0 thorn0 commented May 17, 2014

The term 'observer' isn't used anywhere else throughout the documentation to refer to scope changes handlers. Also I don't see a need in using $ here.

The term 'observer' isn't used anywhere else throughout the documentation to refer to the scope changes handler. Also I don't see a need in using $ here.
@mary-poppins
Copy link

Thanks for the PR! Please check the items below to help us merge this faster. See the contributing docs for more information.

  • Uses the issue template (#7497)

If you need to make changes to your pull request, you can update the commit with git commit --amend.
Then, update the pull request with git push -f.

Thanks again for your help!

@thorn0 thorn0 added cla: yes and removed cla: no labels May 19, 2014
When you change the `$location` inside the `$digest` phase everything is ok; `$location` will
propagate this change into browser and will notify all the $watchers / $observers.
propagate this change into browser and will notify all the watchers.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it would be better to just link to the Scope / Attributes methods instead, to mitigate the confusion? I think links are good.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, this has been fixed a bit differently in d8c5586 --- but the PR is appreciated, please help us make the docs even clearer, there is a lot more of that left to do

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need to mention the $observe method here in the first place? Watchers are used for a lot of different things. And $observe is just one of them. If we are talking about the scope life-cycle and watchers in general, why mention this specific use case? That was my point.

Also, you've kept the dollar signs here: 'all the $watchers / $observers'. What for? For those not in the know, it seems that 'watchers' and '$watchers' might be different things. An example of such $confusion: http://ng.malsup.com/#!/scope-vs-$scope

caitp added a commit that referenced this pull request May 21, 2014
… with links

Add links to API docs for Scope#$watch and Attributes#$observe in $location in order to clarify
the meaning of that terminology.

Closes #7497
@caitp caitp closed this in d8c5586 May 21, 2014
RichardLitt pushed a commit to RichardLitt/angular.js that referenced this pull request May 24, 2014
… with links

Add links to API docs for Scope#$watch and Attributes#$observe in $location in order to clarify
the meaning of that terminology.

Closes angular#7497
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants