PRIVATE
Extends: Ember.Object
Defined in: packages/ember-routing/lib/location/hash_location.js:15
Module: ember-routing
Ember.HashLocation implements the location API using the browser's hash. At present, it relies on a hashchange event existing in the browser.
Given a URL, formats it to be placed into the page as part of an element's href attribute.
This is used, for example, when using the {{action}} helper to generate a URL based on an event.
String
Returns the normalized URL, constructed from location.hash.
e.g. #/foo => /foo as well as #/foo#bar => /foo#bar.
By convention, hashed paths must begin with a forward slash, otherwise they are not treated as a path so we can distinguish intent.
Register a callback to be invoked when the hash changes. These callbacks will execute when the user presses the back or forward button, but not after setURL is invoked.
Function
Uses location.replace to update the url without a page reload or history modification.
String
Set the location.hash and remembers what was set. This prevents onUpdateURL callbacks from triggering when the hash was set by HashLocation.
String
Cleans up the HashLocation event listener.
© 2017 Yehuda Katz, Tom Dale and Ember.js contributors
Licensed under the MIT License.
http://emberjs.com/api/classes/Ember.HashLocation.html