Skip to content

Commit

Permalink
- Fixed issue #940
Browse files Browse the repository at this point in the history
  • Loading branch information
ferdikoomen committed Jan 26, 2022
1 parent 8673f06 commit a159e77
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/templates/index.hbs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{{>header}}

{{#if @root.exportClient}}
export { AppClient } from './client';
export { {{{clientName}}} } from './client';
{{/if}}
{{#if @root.exportCore}}
export { ApiError } from './core/ApiError';
Expand Down
1 change: 1 addition & 0 deletions src/utils/writeClientIndex.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export const writeClientIndex = async (
exportSchemas,
useUnionTypes,
postfix,
clientName,
server: client.server,
version: client.version,
models: sortModelsByName(client.models),
Expand Down
2 changes: 1 addition & 1 deletion test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const generate = async (input, output) => {
exportSchemas: true,
exportModels: true,
exportServices: true,
// clientName: 'AppClient',
// clientName: 'DemoAppClient',
// indent: OpenAPI.Indent.SPACE_2,
// postfix: 'Api',
// request: './test/custom/request.ts',
Expand Down

0 comments on commit a159e77

Please sign in to comment.