Mike Rockétt

Vue Routisan Beta

Elegant, fluent route definitions for Vue Router, inspired by Laravel.

Repository: https://github.com/mikerockett/vue-routisan


Routisan 3 is currently in beta. Stable release around the corner!

$ npm i vue-routisan@next # or yarn add vue-routisan@next

Routisan provides you with a friendlier way to declare route definitions for Vue Router. Inspired by Laravel, it uses chained calls to build up your routes, allowing you to group and nest as deeply as you like.

Route.view('blog', 'Blog').name('blog').children(() => {
// All Posts
Route.view('/', 'Blog/Posts').name('posts')
// Single Post
Route.view('{post}', 'Blog/Post').name('single-post').children(() => {
Route.view('edit', 'Blog/Post/Edit').name('edit')
Route.view('stats', 'Blog/Post/Stats').name('stats')

This produces an array of routes in the format Vue Router expects to see, and follows a behaviour somewhat similar to Laravel’s router, such as:

  • Using callbacks to iteratively collect routes
  • Correctly joining nested routes together, regardles of prefixed slashes
  • Correctly joining the names of nested routes, using a separator of your choice


You can read the docs on the Vue Routisan 3 site.

Upgrading from v2.x

If you are upgrading a project to Routisan 3, please consult the upgrade guide.

Keep in mind that Routisan 3 is currently in beta. It is suitable for production use, but it would be wise to wait for the stable release before using it in large projects where potential breaking changes might make the upgrade path unnecessarily complex.


Routisan’s changelog is maintained here.


Vue Routisan is licensed under the ISC license, which is more permissive variant of the MIT license. You can read the license here.


If you would like to contribute code to Vue Routisan, simply open a Pull Request containing the changes you would like to see. Please provide a proper description of the changes, whether they fix a bug, enhance an existing feature, or add a new feature.

If you spot a bug and don’t know how to fix it (or just don’t have the time), simply open an issue. Please ensure the issue is descriptive, and contains a link to a reproduction of the issue. Additionally, please prefix the title with the applicable version of Routisan, such as [3.0].

Feature requests may also be submitted by opening an issue – please prefix the title with “Feature Request”

Published 18 July 2021 in Vue