fix(frontend): SSR of create.vue working, add .vscode launch.json, fix launch.json bug due to typescript in nuxt.config.ts

This commit is contained in:
2025-03-01 10:14:45 +01:00
parent c07e03d593
commit 9538181865
7 changed files with 74 additions and 21 deletions

View File

@@ -1,13 +1,13 @@
import { ApplicationFormApi, Configuration } from '../.api-client'
import type { CreateApplicationFormDto, ApplicationFormDto, PagedApplicationFormDto } from '~/.api-client'
import { cleanDoubleSlashes } from 'ufo'
import { cleanDoubleSlashes, withoutTrailingSlash } from 'ufo'
export function useApplicationFormApi() {
const appBaseUrl = useRuntimeConfig().app.baseURL
const { serverApiBaseUrl, serverApiBasePath, clientProxyBasePath } = useRuntimeConfig().public
const basePath = cleanDoubleSlashes(
import.meta.client ? appBaseUrl + clientProxyBasePath : serverApiBaseUrl + serverApiBasePath
const basePath = withoutTrailingSlash(
cleanDoubleSlashes(import.meta.client ? appBaseUrl + clientProxyBasePath : serverApiBaseUrl + serverApiBasePath)
)
const applicationFormApiClient = new ApplicationFormApi(new Configuration({ basePath }))