MCPcopy Create free account
hub / github.com/hey-api/hey-api / clientFolderAbsolutePath

Function clientFolderAbsolutePath

packages/openapi-ts/src/generate/client.ts:44–56  ·  view source on GitHub ↗
(config: Config)

Source from the content-addressed store, hash-verified

42 * Returns absolute path to the client folder. This is hard-coded for now.
43 */
44export function clientFolderAbsolutePath(config: Config): string {
45 const client = getClientPlugin(config);
46
47 if ('bundle' in client.config && client.config.bundle) {
48 // not proud of this one
49 const renamed: Map<string, string> | undefined =
50 // @ts-expect-error
51 config._FRAGILE_CLIENT_BUNDLE_RENAMED;
52 return path.resolve(config.output.path, 'client', `${renamed?.get('index') ?? 'index'}.ts`);
53 }
54
55 return client.name;
56}
57
58/**
59 * Recursively copies files and directories.

Callers 4

createClientFunction · 0.90
createClientConfigTypeFunction · 0.90
sdkSymbolsFunction · 0.90
createQueryKeyFunctionFunction · 0.90

Calls 3

getClientPluginFunction · 0.90
getMethod · 0.65
resolveMethod · 0.45

Tested by

no test coverage detected