-
-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pluginClient: client=fetch does not work #1463
Comments
Are you sure about this because the fetch client is using fetch behind the scenes, see https://github.com/kubb-labs/kubb/blob/main/packages/plugin-client/src/clients/fetch.ts |
I checked again: The generated
I think this needs to be changed to make it work properly. Other (minor) things:
should be changed to
and
should be changed to
|
@nimo23 Could you have another look, I did some changes that should reflect more what was needed, see v.3.3.3 |
@stijnvanhulle Thanks! I tried it and now it works almost correct. However, the default
If I customize the
then it works. However, according to https://www.kubb.dev/plugins/plugin-client/#baseurl, the default I think it should set the default
|
What version of
kubb
is running?3.3.0
What kind of platform do you use?
MacOS
How does your
kubb.config.ts
config look likeSwagger/OpenAPI file?
No response
What version of external packages are you using(
@tanstack-query
,MSW
,React
,Vue
, ...)react 19.0.0
What steps can reproduce the bug?
client: 'fetch'
instead ofclient: 'axios'
inpluginClient
clients
folderFor example, this is the resource generated for:
clients/fetch/getUserByUserName.ts
:Looking into
@kubb/plugin-client/clients/fetch
, it uses theaxios
client instead offetch()
api:How often does this bug happen?
Every time
What is the expected behavior?
Something like the following file (which was previously needed (before kubb 3.3.3) to be included via
importPath: 'src/fetchRequest.ts'
):Additional information
No response
The text was updated successfully, but these errors were encountered: