Taxi.js

Taxi is a small and snappy js library for adding slick PJAX navigation and beautiful transitions to your website.
GitHub
576
Created 3 years ago, last commit 7 days ago
3 contributors
92 commits
Stars added on GitHub, month by month
12
1
2
3
4
5
6
7
8
9
10
11
2023
2024
Stars added on GitHub, per day, on average
Yesterday
=
Last week
0.0
/day
Last month
+0.2
/day
Last 12 months
+0.2
/day
npmPackage on NPM
Monthly downloads on NPM
12
1
2
3
4
5
6
7
8
9
10
11
2023
2024
README

Taxi.js is the spiritual successor to Highway.js.

Full Documentation

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)
  • Auto runs javascript on the new page
  • Previous page's content is automatically removed (you can opt out of this if you like)
  • Click events on links can be intercepted via stopPropagation without hacks

Differences to Highway

  • Different public API
  • New methods and functionality
  • data-taxi, data-taxi-view, data-taxi-ignore are to be used instead of data-router-wrapper, data-router-view, data-router-disabled respectively.
  • attach and detach are no longer methods - link clicks are listened to via delegation so these are no longer needed.
  • redirect is now navigateTo as "redirect" felt weird as a method name!
  • Renderers now have an initialLoad method
  • 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.

Full Documentation