Skip to content

Commit

Permalink
use HTML 5 history mode for vue frontend
Browse files Browse the repository at this point in the history
  • Loading branch information
vabene1111 committed Sep 25, 2024
1 parent 0db439c commit 0a3611b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions cookbook/urls.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from pydoc import locate

from django.urls import include, path
from django.urls import include, path, re_path
from django.views.generic import TemplateView
from drf_spectacular.views import SpectacularAPIView
from rest_framework import routers
Expand Down Expand Up @@ -76,7 +76,8 @@ def extend(self, r):

urlpatterns = [
path('', views.index, name='index'),
path('v3/', views.vue3, name='vue3'),
re_path(r'^v3/.*', views.vue3, name='vue3'),
#path('v3/', views.vue3, name='vue3'),
path('setup/', views.setup, name='view_setup'),
path('no-group', views.no_groups, name='view_no_group'),
path('space-overview', views.space_overview, name='view_space_overview'),
Expand Down
4 changes: 2 additions & 2 deletions vue3/src/apps/tandoor/main.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {createApp} from "vue";
import {createRouter, createWebHashHistory} from 'vue-router'
import {createRouter, createWebHashHistory, createWebHistory} from 'vue-router'
import {createPinia} from 'pinia'
// @ts-ignore
import App from './Tandoor.vue'
Expand Down Expand Up @@ -56,7 +56,7 @@ const routes = [

const router = createRouter({
// TODO configure proper history mode
history: createWebHashHistory(),
history: createWebHistory('v3/'),
routes,
})

Expand Down

0 comments on commit 0a3611b

Please sign in to comment.