Our backend routing on admin is a hybrid routing. What it means is we use laravel’s router and middleware to restrict the admin route and then use the vueJS router for backend inner routes when a user is already logged in.
Here is a simple diagram on how it is setup.
The backend route is powered by vueJs’s vue-router, to know more on how to work with vue-router, please see the documentation of vue-router here: https://router.vuejs.org/en/
The vue router file on our backend dashboard is located at:
If you open this file, you will see the defined routes for our single page app routing.