@acrool/react-fetcher 0.0.2-alpha.7 → 0.0.2-alpha.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/FetcherProvider/FetcherProvider.d.ts +4 -3
- package/dist/FetcherProvider/index.d.ts +2 -1
- package/dist/FetcherProvider/types.d.ts +2 -1
- package/dist/FetcherProvider/utils.d.ts +9 -4
- package/dist/acrool-react-fetcher.es.js +817 -808
- package/dist/fetchers/createGraphQLFetcher/createGraphQLFetcher.d.ts +1 -1
- package/dist/fetchers/createRestFulFetcher/config.d.ts +1 -1
- package/dist/fetchers/createRestFulFetcher/index.d.ts +1 -0
- package/dist/fetchers/createRestFulFetcher/types.d.ts +2 -10
- package/dist/fetchers/createRestFulFetcher/utils.d.ts +2 -2
- package/package.json +1 -1
|
@@ -1,15 +1,7 @@
|
|
|
1
1
|
import { IRequestConfig } from '../types';
|
|
2
|
-
export
|
|
3
|
-
params?: TVariables['params'];
|
|
4
|
-
body?: TVariables['body'];
|
|
5
|
-
variables?: TVariables['variables'];
|
|
2
|
+
export type IUseFetcherArgs<TVariables> = TVariables | (TVariables & {
|
|
6
3
|
fetchOptions?: IRequestConfig;
|
|
7
|
-
}
|
|
8
|
-
export interface IObjectArgs {
|
|
9
|
-
params?: unknown;
|
|
10
|
-
variables?: unknown;
|
|
11
|
-
body?: unknown;
|
|
12
|
-
}
|
|
4
|
+
});
|
|
13
5
|
export interface IDocument {
|
|
14
6
|
url: string;
|
|
15
7
|
method?: string;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ERequestHeaderContentType } from './config';
|
|
2
2
|
/**
|
|
3
3
|
*
|
|
4
4
|
* @param obj 送出物件
|
|
5
5
|
* @param contentType
|
|
6
6
|
*/
|
|
7
|
-
export declare function flattenObjectToFormData(obj: Record<string, any>, contentType:
|
|
7
|
+
export declare function flattenObjectToFormData(obj: Record<string, any>, contentType: ERequestHeaderContentType): {
|
|
8
8
|
body: FormData | string;
|
|
9
9
|
contentType: string;
|
|
10
10
|
};
|