Skip to content

Commit

Permalink
fix(ui): Use web hash history in ui (fix #3481) (#3487)
Browse files Browse the repository at this point in the history
Co-authored-by: Vladimir <sleuths.slews0s@icloud.com>
  • Loading branch information
segevfiner and sheremet-va authored Aug 24, 2023
1 parent 7dac059 commit 8caabaa
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion packages/ui/client/composables/params.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ export interface Params {
view: null | 'graph' | 'editor' | 'console'
}

export const params = useUrlSearchParams<Params>('hash-params', {
export const params = useUrlSearchParams<Params>('hash', {
initialValue: {
file: '',
view: null,
Expand Down
5 changes: 2 additions & 3 deletions packages/ui/client/global-setup.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/// <reference types="vite-plugin-pages/client" />

import { createRouter as _createRouter, createWebHistory } from 'vue-router'
import { createRouter as _createRouter, createWebHashHistory } from 'vue-router'
import FloatingVue, { VTooltip } from 'floating-vue'
import routes from 'virtual:generated-pages'
import 'd3-graph-controller/default.css'
Expand All @@ -11,7 +11,6 @@ import 'codemirror-theme-vars/base.css'
import './styles/main.css'
import 'floating-vue/dist/style.css'
import 'uno.css'
import { BASE_PATH } from './constants'

export const directives = {
tooltip: VTooltip,
Expand All @@ -22,7 +21,7 @@ FloatingVue.options.distance = 10

export function createRouter() {
return _createRouter({
history: createWebHistory(BASE_PATH),
history: createWebHashHistory(),
routes,
})
}
Expand Down

0 comments on commit 8caabaa

Please sign in to comment.