This is a utility library which simplifies handling click events for multiple links. It aims to provide simple and correct helpers which work with the DOM and with generic URL syntax.
Using CommonJS:
var LinkWatcher = require('link-watcher');
LinkWatcher.onLinkClicked(/* ... */);
As a browser global:
<script src="link-watcher.min.js"></script>
<script>
LinkWatcher.onLinkClicked(/* ... */);
</script>
onLinkClicked(rootElement, callback, options)
getNavigationInfo(event, rootInfo)
urlResolve(url)
- documentation
- work out whether IRIs are supported
- work with SVG links
- work with form submission?