@shipengine/react-api 2.12.0 → 2.13.0
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/package.json +1 -1
- package/utilities/types.d.ts +8 -1
package/package.json
CHANGED
package/utilities/types.d.ts
CHANGED
|
@@ -5,11 +5,18 @@ import { CodedError } from "@shipengine/js-api";
|
|
|
5
5
|
* @category Entities
|
|
6
6
|
* Generic object type to be used in any useQuery hook
|
|
7
7
|
* @param TResponseData - The response data type from the query
|
|
8
|
-
* @param TQueryFnParams - The data type for the queryFnParams
|
|
8
|
+
* @param TQueryFnParams - Optional - The data type for the queryFnParams
|
|
9
9
|
*/
|
|
10
10
|
export type QueryProps<TResponseData, TQueryFnParams = unknown> = {
|
|
11
11
|
queryFnParams?: TQueryFnParams;
|
|
12
12
|
} & Pick<UseQueryOptions<AxiosResponse<TResponseData, any>, CodedError[], TResponseData>, "cacheTime" | "enabled" | "staleTime">;
|
|
13
|
+
/**
|
|
14
|
+
* @category Entities
|
|
15
|
+
* Generic object type to be used in any useQuery hook
|
|
16
|
+
* @param TResponseData - The response data type from the query
|
|
17
|
+
* @param TQueryFnParams - The data type for the queryFnParams
|
|
18
|
+
*/
|
|
19
|
+
export type QueryPropsRequiredParams<TResponseData, TQueryFnParams = unknown> = QueryProps<TResponseData, TQueryFnParams> & Required<Pick<QueryProps<TResponseData, TQueryFnParams>, "queryFnParams">>;
|
|
13
20
|
/**
|
|
14
21
|
* @category Entities
|
|
15
22
|
* Generic object type to be used in any useMutation hook
|