An open API service indexing awesome lists of open source software.

https://github.com/sapegin/hashnav

Simplest JavaScript hash navigation.
https://github.com/sapegin/hashnav

Last synced: 3 months ago
JSON representation

Simplest JavaScript hash navigation.

Awesome Lists containing this project

README

          

# HashNav

Simplest JavaScript hash navigation.

## API

### HashNav.initial(value)

- value {String | undefined}

Get/set default hash. Default hash is a hash that will never visible in URL. It’s a default state of a page.

### HashNav.change(value)

- value {String | Function}

Set/execute change handler. `HashNav.change('foo')` will set page has to `#foo` and execute all handlers added via `HashNav.change(function(hash) { ... })`.

## Example

See `demo.html`.

## Changelog

The changelog can be found in the `Changelog.md` file.

---

## License

The MIT License, see the included `License.md` file.