diff --git a/generator/konfig-generator-api/src/main/resources/typescript-axios/api_doc_example_setup.mustache b/generator/konfig-generator-api/src/main/resources/typescript-axios/api_doc_example_setup.mustache index d3f3d054e8..abd65fa642 100644 --- a/generator/konfig-generator-api/src/main/resources/typescript-axios/api_doc_example_setup.mustache +++ b/generator/konfig-generator-api/src/main/resources/typescript-axios/api_doc_example_setup.mustache @@ -7,10 +7,6 @@ const {{{clientNameLowercase}}} = new {{{clientName}}}({ {{{apiDocumentationAuthenticationPartial}}} {{/apiDocumentationAuthenticationPartial}} {{^apiDocumentationAuthenticationPartial}} -{{#includeFetchAdapter}} - // Use native Fetch API instead of axios - // useFetch: true, -{{/includeFetchAdapter}} {{> api_doc_example_setup_parameters}} {{/apiDocumentationAuthenticationPartial}} }) \ No newline at end of file diff --git a/generator/konfig-generator-api/src/main/resources/typescript-axios/configuration.mustache b/generator/konfig-generator-api/src/main/resources/typescript-axios/configuration.mustache index 977b43afeb..93b1f3af8b 100644 --- a/generator/konfig-generator-api/src/main/resources/typescript-axios/configuration.mustache +++ b/generator/konfig-generator-api/src/main/resources/typescript-axios/configuration.mustache @@ -141,7 +141,7 @@ export class Configuration { this.basePath = param.basePath; this.baseOptions = param.baseOptions ?? {}; {{#includeFetchAdapter}} - if (param.useFetch) { + if (param.useFetch ?? true) { this.baseOptions["adapter"] = fetchAdapter } {{/includeFetchAdapter}}