O'Reilly logo

Isomorphic Go by Kamesh Balasubramanian

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Registering client-side routes with the isokit router

On the client side, we use the isokit router to handle routes. The isokit router works by intercepting the click events to hyperlinks and checking if the hyperlink contains a route defined in its routing table.

We can register a route in the router's routing table using the Handle method of the isokit router object. The Handle method takes two parameters—the first parameter is the route and the second parameter is the handler function that should service the route. Notice that the code to declare and register routes is very similar to the Gorilla Mux router on the server side. Because of this similarity, registering routes on the client side, with the isokit router, is straightforward ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required