feat(ui): add 'Not found' catch all
[e-mobility-charging-stations-simulator.git] / ui / web / src / router / index.ts
index bdb22503198337c01c2786bea3dc72c3156be686..23cca6a4913c23e3d65ecaceae24c539ad4c5010 100644 (file)
@@ -3,6 +3,7 @@ import ChargingStationsView from '@/views/ChargingStationsView.vue'
 import StartTransaction from '@/components/actions/StartTransaction.vue'
 import AddChargingStations from '@/components/actions/AddChargingStations.vue'
 import SetSupervisionUrl from '@/components/actions/SetSupervisionUrl.vue'
+import NotFoundView from '@/views/NotFoundView.vue'
 
 export const router = createRouter({
   history: createWebHistory(),
@@ -39,6 +40,13 @@ export const router = createRouter({
         action: StartTransaction
       },
       props: { default: false, action: true }
+    },
+    {
+      name: 'not-found',
+      path: '/:pathMatch(.*)*',
+      components: {
+        default: NotFoundView
+      }
     }
   ]
 })