3 ms·
You can do this with Axios too: interface IResponse { foo: string } async function doSomething() { const reponse: AxiosResponse<IResponse> = a
by indexerror 8y ago
You can do this with Axios too:
interface IResponse {
foo: string
}
async function doSomething() {
const reponse: AxiosResponse<IResponse> = await Api.call()
...
// or you can use AxiosPromise<IResponse> without the await
}