diff --git a/composables/use-roadiz-web-response.ts b/composables/use-roadiz-web-response.ts index 1b34093..0954fd1 100644 --- a/composables/use-roadiz-web-response.ts +++ b/composables/use-roadiz-web-response.ts @@ -1,6 +1,9 @@ import type { RoadizWebResponse } from '@roadiz/types' +import { joinURL } from 'ufo' + +export async function useRoadizWebResponse(path?: string) { + path = joinURL('/', path || useRoute().path) -export async function useRoadizWebResponse(path: string) { const fetch = useRoadizFetchFactory() const { data } = await useAsyncData(async () => { try {