Skip to content
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

Type 'void' is not assignable to type 'AxiosHeaders...' #4

Open
shaon72 opened this issue Aug 14, 2023 · 0 comments
Open

Type 'void' is not assignable to type 'AxiosHeaders...' #4

shaon72 opened this issue Aug 14, 2023 · 0 comments

Comments

@shaon72
Copy link

shaon72 commented Aug 14, 2023

No overload matches this call. Overload 1 of 2, '(config: AxiosRequestConfig<any>): Promise<AxiosResponse<any, any>>', gave the following error. Type 'void' is not assignable to type 'AxiosHeaders | (Partial<RawAxiosHeaders & { Accept: AxiosHeaderValue; "Content-Length": AxiosHeaderValue; "User-Agent": AxiosHeaderValue; "Content-Encoding": AxiosHeaderValue; Authorization: AxiosHeaderValue; } & { ...; }> & Partial<...>) | undefined'. Overload 2 of 2, '(url: string, config?: AxiosRequestConfig<any> | undefined): Promise<AxiosResponse<any, any>>', gave the following error. Argument of type '{ method: Method; url: string; data: any; headers: void; }' is not assignable to parameter of type 'string'.ts(2769) index.d.ts(312, 3): The expected type comes from property 'headers' which is declared here on type 'AxiosRequestConfig<any>'

The setHeader function at /frontend/src/utils/request-service.tsx seems to be causing this issue @merikbest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant