@ianmartorell/restyped-axios
Advanced tools
Comparing version 2.0.1 to 2.0.2
import { AxiosInstance, AxiosRequestConfig, AxiosResponse, CancelStatic, CancelTokenStatic } from 'axios'; | ||
import { RestypedBase, RestypedIndexedBase, RestypedRoute } from 'restyped'; | ||
export interface TypedAxiosRequestConfig<API extends RestypedIndexedBase, Path extends Extract<keyof API, string>, Method extends keyof API[Path], RouteDef extends RestypedRoute = API[Path][Method]> extends AxiosRequestConfig { | ||
import { RestypedBase, RestypedRoute } from 'restyped'; | ||
export interface TypedAxiosRequestConfig<API extends RestypedBase, Path extends Extract<keyof API, string>, Method extends keyof API[Path], RouteDef extends RestypedRoute = API[Path][Method]> extends AxiosRequestConfig { | ||
url?: Path; | ||
@@ -9,3 +9,3 @@ method?: Extract<Method, string>; | ||
} | ||
export interface TypedAxiosResponse<API extends RestypedIndexedBase, Path extends Extract<keyof API, string>, Method extends keyof API[Path], RouteDef extends RestypedRoute = API[Path][Method]> extends AxiosResponse { | ||
export interface TypedAxiosResponse<API extends RestypedBase, Path extends Extract<keyof API, string>, Method extends keyof API[Path], RouteDef extends RestypedRoute = API[Path][Method]> extends AxiosResponse { | ||
data: RouteDef['response']; | ||
@@ -12,0 +12,0 @@ config: TypedAxiosRequestConfig<API, Path, Method>; |
{ | ||
"name": "@ianmartorell/restyped-axios", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "Axios typings for consuming RESTyped APIs", | ||
@@ -5,0 +5,0 @@ "main": "./dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8231