mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-08-24 08:01:38 +00:00
small nit BASE_URL
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
import { goto as svelteGoto } from '$app/navigation'
|
||||
import { base } from '$app/paths'
|
||||
import { base as svelteBase } from '$app/paths'
|
||||
export { base } from '$lib/base'
|
||||
|
||||
export function goto(path, options = {}) {
|
||||
if (base == '') {
|
||||
if (svelteBase == '') {
|
||||
return svelteGoto(path, options)
|
||||
} else {
|
||||
const fullPath = path.startsWith(base) ? path : `${base}${path}`
|
||||
const fullPath = path.startsWith(svelteBase) ? path : `${svelteBase}${path}`
|
||||
return svelteGoto(fullPath, options)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user