mirror of
https://github.com/nocodb/nocodb.git
synced 2026-04-29 23:16:59 +00:00
14 lines
335 B
TypeScript
14 lines
335 B
TypeScript
import { computed, useRoute } from '#imports'
|
|
|
|
export function useDashboard() {
|
|
const route = useRoute()
|
|
|
|
const dashboardUrl = computed(() => {
|
|
// todo: test in different scenarios
|
|
// get base path of app
|
|
return `${location.origin}${(location.pathname || '').replace(route.path, '')}`
|
|
})
|
|
|
|
return { dashboardUrl }
|
|
}
|