Taxi.js is the spiritual successor to Highway.js.
npm i @unseenco/taxi or
yarn add @unseenco/taxi
Taxi is a js library for adding AJAX navigation and beautiful transitions to your website.
It was designed as a drop-in replacement for Highway.js which is sadly no longer maintained.
Enhancements over Highway:
- URL-based routing
- Better cache management
- Ability to preload URLs
- Blocks navigation during an active transition (can be opted out)
- Previous page's content is automatically removed (you can opt out of this if you like)
- Click events on links can be intercepted via
Differences to Highway
- Different public API
- New methods and functionality
data-taxi-ignoreare to be used instead of
detachare no longer methods - link clicks are listened to via delegation so these are no longer needed.
navigateToas "redirect" felt weird as a method name!
- Renderers now have an
- The params passed to renderers, transitions, and events are now a little different
- Old content is automatically removed during a transition - so no need to manually call
from.remove()in your transitions.