Ive seen this on a lot of sites lately, for example,
http://guides.rubyonrails.org/active_record_querying.html, where its one page, and one the side you have links, clicking them scrolls down to a specific section of the page.
I get that I can use jQuery to scroll to specific section of a page based on pixels/page height, but I notice that the url is also changing to mirror the id of the page section after a # sign? So like:
Clicking the 'retrieve a single object link' changes the url to:
http://edgeguides.rubyonrails.org/active_record_querying.html#retrieving-a-single-object
and scrolls down to that section
How is this implemented, (it would be helpful if you could provide an answer in the context of a ruby on rails application)?