Nerdy Programmers Mingling
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

href-router

0.0.2 • Public • Published

href router

catch links that end with ! and emit js events. useful for lightweight app routing (uses a single global 'live' listener)

requires zepto.js with the .live and .tap components loaded. for mobile browsers you should use https://github.com/ftlabs/fastclick

usage

function onModal(route) { app.emit('modal', route) }
hrefRouter.catchRoutes(onModal, $('.container')[0])

BSD LICENSE

Keywords

none

install

npm i href-router

Downloadsweekly downloads

4

version

0.0.2

license

none

last publish

collaborators

  • avatar
Report a vulnerability