routesync 1.0.33 → 1.0.35
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/react.d.mts +14 -6
- package/dist/react.d.ts +14 -6
- package/dist/react.js +8 -8
- package/dist/react.mjs +8 -8
- package/dist/sdk.d.mts +12 -4
- package/dist/sdk.d.ts +12 -4
- package/package.json +1 -1
package/dist/react.d.mts
CHANGED
|
@@ -51,16 +51,24 @@ type CallOptions<TParams = unknown, TBody = unknown> = {
|
|
|
51
51
|
body?: TBody;
|
|
52
52
|
headers?: Record<string, string>;
|
|
53
53
|
};
|
|
54
|
-
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
54
|
+
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
55
|
+
params?: never;
|
|
56
|
+
} : {
|
|
55
57
|
params: TParams;
|
|
56
58
|
}) & (unknown extends TBody ? {
|
|
57
|
-
body?:
|
|
59
|
+
body?: TBody;
|
|
58
60
|
} : {
|
|
59
61
|
body: TBody;
|
|
60
62
|
}) & {
|
|
61
63
|
query?: Record<string, any>;
|
|
62
64
|
headers?: Record<string, string>;
|
|
63
65
|
};
|
|
66
|
+
type LooseEndpointOptions = {
|
|
67
|
+
params?: unknown;
|
|
68
|
+
query?: Record<string, unknown>;
|
|
69
|
+
body?: unknown;
|
|
70
|
+
headers?: Record<string, string>;
|
|
71
|
+
};
|
|
64
72
|
type RequiredKeys<T> = {
|
|
65
73
|
[K in keyof T]-?: {} extends Pick<T, K> ? never : K;
|
|
66
74
|
}[keyof T];
|
|
@@ -72,7 +80,7 @@ interface ApiError {
|
|
|
72
80
|
}
|
|
73
81
|
interface EndpointCallable<TResponse = unknown, TParams = unknown, TBody = unknown> {
|
|
74
82
|
(...args: OptionalIfEmpty<EndpointCallableOptions<TParams, TBody>>): Promise<TResponse>;
|
|
75
|
-
(options:
|
|
83
|
+
(options: LooseEndpointOptions | undefined): Promise<TResponse>;
|
|
76
84
|
(options: CallOptions<TParams, TBody>): Promise<TResponse>;
|
|
77
85
|
/** Original RouteDefinition — used by useApiQuery / useApiMutation */
|
|
78
86
|
$def: RouteDefinition<TResponse, TParams, TBody>;
|
|
@@ -84,9 +92,9 @@ interface EndpointCallable<TResponse = unknown, TParams = unknown, TBody = unkno
|
|
|
84
92
|
|
|
85
93
|
type ApiQueryOptions<TResponse, TError = ApiError, TData = TResponse> = Omit<UseQueryOptions<TResponse, TError, TData>, 'queryKey' | 'queryFn'>;
|
|
86
94
|
declare function useApiQuery<TResponse, TParams, TBody, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options: EndpointCallableOptions<TParams, TBody>, queryOptions?: ApiQueryOptions<TResponse, TError, TData>): ReturnType<typeof useQuery<TResponse, TError, TData>>;
|
|
87
|
-
declare function useApiQuery<TResponse, TParams, TBody, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?:
|
|
88
|
-
declare function useApiSuspenseQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?:
|
|
89
|
-
declare function useApiInfiniteQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = InfiniteData<TResponse>, TPageParam = unknown>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options:
|
|
95
|
+
declare function useApiQuery<TResponse, TParams, TBody, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?: LooseEndpointOptions, queryOptions?: ApiQueryOptions<TResponse, TError, TData>): ReturnType<typeof useQuery<TResponse, TError, TData>>;
|
|
96
|
+
declare function useApiSuspenseQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?: LooseEndpointOptions, queryOptions?: Omit<UseSuspenseQueryOptions<TResponse, TError, TData>, 'queryKey' | 'queryFn'>): _tanstack_react_query.UseSuspenseQueryResult<TData, TError>;
|
|
97
|
+
declare function useApiInfiniteQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = InfiniteData<TResponse>, TPageParam = unknown>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options: LooseEndpointOptions | undefined, queryOptions: Omit<UseInfiniteQueryOptions<TResponse, TError, TData, any, TPageParam>, 'queryKey' | 'queryFn'> & {
|
|
90
98
|
getNextPageParam: UseInfiniteQueryOptions<TResponse, TError, TData, any, TPageParam>['getNextPageParam'];
|
|
91
99
|
}): _tanstack_react_query.UseInfiniteQueryResult<TData, TError>;
|
|
92
100
|
|
package/dist/react.d.ts
CHANGED
|
@@ -51,16 +51,24 @@ type CallOptions<TParams = unknown, TBody = unknown> = {
|
|
|
51
51
|
body?: TBody;
|
|
52
52
|
headers?: Record<string, string>;
|
|
53
53
|
};
|
|
54
|
-
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
54
|
+
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
55
|
+
params?: never;
|
|
56
|
+
} : {
|
|
55
57
|
params: TParams;
|
|
56
58
|
}) & (unknown extends TBody ? {
|
|
57
|
-
body?:
|
|
59
|
+
body?: TBody;
|
|
58
60
|
} : {
|
|
59
61
|
body: TBody;
|
|
60
62
|
}) & {
|
|
61
63
|
query?: Record<string, any>;
|
|
62
64
|
headers?: Record<string, string>;
|
|
63
65
|
};
|
|
66
|
+
type LooseEndpointOptions = {
|
|
67
|
+
params?: unknown;
|
|
68
|
+
query?: Record<string, unknown>;
|
|
69
|
+
body?: unknown;
|
|
70
|
+
headers?: Record<string, string>;
|
|
71
|
+
};
|
|
64
72
|
type RequiredKeys<T> = {
|
|
65
73
|
[K in keyof T]-?: {} extends Pick<T, K> ? never : K;
|
|
66
74
|
}[keyof T];
|
|
@@ -72,7 +80,7 @@ interface ApiError {
|
|
|
72
80
|
}
|
|
73
81
|
interface EndpointCallable<TResponse = unknown, TParams = unknown, TBody = unknown> {
|
|
74
82
|
(...args: OptionalIfEmpty<EndpointCallableOptions<TParams, TBody>>): Promise<TResponse>;
|
|
75
|
-
(options:
|
|
83
|
+
(options: LooseEndpointOptions | undefined): Promise<TResponse>;
|
|
76
84
|
(options: CallOptions<TParams, TBody>): Promise<TResponse>;
|
|
77
85
|
/** Original RouteDefinition — used by useApiQuery / useApiMutation */
|
|
78
86
|
$def: RouteDefinition<TResponse, TParams, TBody>;
|
|
@@ -84,9 +92,9 @@ interface EndpointCallable<TResponse = unknown, TParams = unknown, TBody = unkno
|
|
|
84
92
|
|
|
85
93
|
type ApiQueryOptions<TResponse, TError = ApiError, TData = TResponse> = Omit<UseQueryOptions<TResponse, TError, TData>, 'queryKey' | 'queryFn'>;
|
|
86
94
|
declare function useApiQuery<TResponse, TParams, TBody, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options: EndpointCallableOptions<TParams, TBody>, queryOptions?: ApiQueryOptions<TResponse, TError, TData>): ReturnType<typeof useQuery<TResponse, TError, TData>>;
|
|
87
|
-
declare function useApiQuery<TResponse, TParams, TBody, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?:
|
|
88
|
-
declare function useApiSuspenseQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?:
|
|
89
|
-
declare function useApiInfiniteQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = InfiniteData<TResponse>, TPageParam = unknown>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options:
|
|
95
|
+
declare function useApiQuery<TResponse, TParams, TBody, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?: LooseEndpointOptions, queryOptions?: ApiQueryOptions<TResponse, TError, TData>): ReturnType<typeof useQuery<TResponse, TError, TData>>;
|
|
96
|
+
declare function useApiSuspenseQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = TResponse>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options?: LooseEndpointOptions, queryOptions?: Omit<UseSuspenseQueryOptions<TResponse, TError, TData>, 'queryKey' | 'queryFn'>): _tanstack_react_query.UseSuspenseQueryResult<TData, TError>;
|
|
97
|
+
declare function useApiInfiniteQuery<TResponse = unknown, TParams = unknown, TBody = unknown, TError = ApiError, TData = InfiniteData<TResponse>, TPageParam = unknown>(endpoint: EndpointCallable<TResponse, TParams, TBody>, options: LooseEndpointOptions | undefined, queryOptions: Omit<UseInfiniteQueryOptions<TResponse, TError, TData, any, TPageParam>, 'queryKey' | 'queryFn'> & {
|
|
90
98
|
getNextPageParam: UseInfiniteQueryOptions<TResponse, TError, TData, any, TPageParam>['getNextPageParam'];
|
|
91
99
|
}): _tanstack_react_query.UseInfiniteQueryResult<TData, TError>;
|
|
92
100
|
|
package/dist/react.js
CHANGED
|
@@ -33,30 +33,30 @@ module.exports = __toCommonJS(src_exports);
|
|
|
33
33
|
// packages/react/src/hooks/useQuery.ts
|
|
34
34
|
var import_react_query = require("@tanstack/react-query");
|
|
35
35
|
function useApiQuery(endpoint, options, queryOptions) {
|
|
36
|
-
const queryKey = endpoint.$
|
|
37
|
-
const callEndpoint = endpoint;
|
|
36
|
+
const queryKey = options ? [...endpoint.$key, options] : endpoint.$key;
|
|
38
37
|
return (0, import_react_query.useQuery)({
|
|
39
38
|
queryKey,
|
|
40
|
-
queryFn: () =>
|
|
39
|
+
queryFn: () => endpoint(options),
|
|
41
40
|
...queryOptions
|
|
42
41
|
});
|
|
43
42
|
}
|
|
44
43
|
function useApiSuspenseQuery(endpoint, options, queryOptions) {
|
|
45
|
-
const queryKey = endpoint.$
|
|
46
|
-
const callEndpoint = endpoint;
|
|
44
|
+
const queryKey = options ? [...endpoint.$key, options] : endpoint.$key;
|
|
47
45
|
return (0, import_react_query.useSuspenseQuery)({
|
|
48
46
|
queryKey,
|
|
49
|
-
queryFn: () =>
|
|
47
|
+
queryFn: () => endpoint(options),
|
|
50
48
|
...queryOptions
|
|
51
49
|
});
|
|
52
50
|
}
|
|
53
51
|
function useApiInfiniteQuery(endpoint, options, queryOptions) {
|
|
54
|
-
const queryKey = endpoint.$
|
|
52
|
+
const queryKey = options ? [...endpoint.$key, options] : endpoint.$key;
|
|
55
53
|
return (0, import_react_query.useInfiniteQuery)({
|
|
56
54
|
queryKey,
|
|
57
55
|
queryFn: ({ pageParam }) => {
|
|
58
56
|
const callOptions = {
|
|
59
|
-
|
|
57
|
+
params: options?.params,
|
|
58
|
+
body: options?.body,
|
|
59
|
+
headers: options?.headers,
|
|
60
60
|
query: { ...options?.query, page: pageParam }
|
|
61
61
|
};
|
|
62
62
|
return endpoint(callOptions);
|
package/dist/react.mjs
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
// packages/react/src/hooks/useQuery.ts
|
|
2
2
|
import { useQuery, useSuspenseQuery, useInfiniteQuery } from "@tanstack/react-query";
|
|
3
3
|
function useApiQuery(endpoint, options, queryOptions) {
|
|
4
|
-
const queryKey = endpoint.$
|
|
5
|
-
const callEndpoint = endpoint;
|
|
4
|
+
const queryKey = options ? [...endpoint.$key, options] : endpoint.$key;
|
|
6
5
|
return useQuery({
|
|
7
6
|
queryKey,
|
|
8
|
-
queryFn: () =>
|
|
7
|
+
queryFn: () => endpoint(options),
|
|
9
8
|
...queryOptions
|
|
10
9
|
});
|
|
11
10
|
}
|
|
12
11
|
function useApiSuspenseQuery(endpoint, options, queryOptions) {
|
|
13
|
-
const queryKey = endpoint.$
|
|
14
|
-
const callEndpoint = endpoint;
|
|
12
|
+
const queryKey = options ? [...endpoint.$key, options] : endpoint.$key;
|
|
15
13
|
return useSuspenseQuery({
|
|
16
14
|
queryKey,
|
|
17
|
-
queryFn: () =>
|
|
15
|
+
queryFn: () => endpoint(options),
|
|
18
16
|
...queryOptions
|
|
19
17
|
});
|
|
20
18
|
}
|
|
21
19
|
function useApiInfiniteQuery(endpoint, options, queryOptions) {
|
|
22
|
-
const queryKey = endpoint.$
|
|
20
|
+
const queryKey = options ? [...endpoint.$key, options] : endpoint.$key;
|
|
23
21
|
return useInfiniteQuery({
|
|
24
22
|
queryKey,
|
|
25
23
|
queryFn: ({ pageParam }) => {
|
|
26
24
|
const callOptions = {
|
|
27
|
-
|
|
25
|
+
params: options?.params,
|
|
26
|
+
body: options?.body,
|
|
27
|
+
headers: options?.headers,
|
|
28
28
|
query: { ...options?.query, page: pageParam }
|
|
29
29
|
};
|
|
30
30
|
return endpoint(callOptions);
|
package/dist/sdk.d.mts
CHANGED
|
@@ -121,16 +121,24 @@ type CallOptions<TParams = unknown, TBody = unknown> = {
|
|
|
121
121
|
body?: TBody;
|
|
122
122
|
headers?: Record<string, string>;
|
|
123
123
|
};
|
|
124
|
-
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
124
|
+
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
125
|
+
params?: never;
|
|
126
|
+
} : {
|
|
125
127
|
params: TParams;
|
|
126
128
|
}) & (unknown extends TBody ? {
|
|
127
|
-
body?:
|
|
129
|
+
body?: TBody;
|
|
128
130
|
} : {
|
|
129
131
|
body: TBody;
|
|
130
132
|
}) & {
|
|
131
133
|
query?: Record<string, any>;
|
|
132
134
|
headers?: Record<string, string>;
|
|
133
135
|
};
|
|
136
|
+
type LooseEndpointOptions = {
|
|
137
|
+
params?: unknown;
|
|
138
|
+
query?: Record<string, unknown>;
|
|
139
|
+
body?: unknown;
|
|
140
|
+
headers?: Record<string, string>;
|
|
141
|
+
};
|
|
134
142
|
type RequiredKeys<T> = {
|
|
135
143
|
[K in keyof T]-?: {} extends Pick<T, K> ? never : K;
|
|
136
144
|
}[keyof T];
|
|
@@ -142,7 +150,7 @@ interface ApiError {
|
|
|
142
150
|
}
|
|
143
151
|
interface EndpointCallable<TResponse = unknown, TParams = unknown, TBody = unknown> {
|
|
144
152
|
(...args: OptionalIfEmpty<EndpointCallableOptions<TParams, TBody>>): Promise<TResponse>;
|
|
145
|
-
(options:
|
|
153
|
+
(options: LooseEndpointOptions | undefined): Promise<TResponse>;
|
|
146
154
|
(options: CallOptions<TParams, TBody>): Promise<TResponse>;
|
|
147
155
|
/** Original RouteDefinition — used by useApiQuery / useApiMutation */
|
|
148
156
|
$def: RouteDefinition<TResponse, TParams, TBody>;
|
|
@@ -310,4 +318,4 @@ declare function mapKeysDeep<T>(value: T, keyCase: KeyCase): T;
|
|
|
310
318
|
declare function toCamelCase<T>(value: T): T;
|
|
311
319
|
declare function toSnakeCase<T>(value: T): T;
|
|
312
320
|
|
|
313
|
-
export { type ApiDefinition, type ApiError, type ApiResponse, type CallOptions, type CamelCasedPropertiesDeep, type CamelToSnake, type EndpointCallable, type EndpointCallableOptions, type EndpointDefinition$1 as EndpointDefinition, GenericService, type GenericServiceOptions, type HttpMethod, type Id, type KeyCase, type OptionalIfEmpty, type ParseResult, type ParserSchema, type QueryParams, type ResourceConfig, type ResourceDefinition, type RouteDefinition, type RouteMapper, type RouteParserSchema, type RouteSchema, type RouteSchemaMap, type RouteSchemaValue, type RouteTransform, type RouteTransformMap, type SchemaLike, type ServiceConfig, type SnakeCasedPropertiesDeep, type SnakeToCamel, type UnknownRecord, camelToSnakeKey, createClient$1 as createClient, createClient as createHttpClient, createService, defineApi, endpoint, generateHooks, mapKeysDeep, parseWithSchema, resource, snakeToCamelKey, toCamelCase, toSnakeCase };
|
|
321
|
+
export { type ApiDefinition, type ApiError, type ApiResponse, type CallOptions, type CamelCasedPropertiesDeep, type CamelToSnake, type EndpointCallable, type EndpointCallableOptions, type EndpointDefinition$1 as EndpointDefinition, GenericService, type GenericServiceOptions, type HttpMethod, type Id, type KeyCase, type LooseEndpointOptions, type OptionalIfEmpty, type ParseResult, type ParserSchema, type QueryParams, type ResourceConfig, type ResourceDefinition, type RouteDefinition, type RouteMapper, type RouteParserSchema, type RouteSchema, type RouteSchemaMap, type RouteSchemaValue, type RouteTransform, type RouteTransformMap, type SchemaLike, type ServiceConfig, type SnakeCasedPropertiesDeep, type SnakeToCamel, type UnknownRecord, camelToSnakeKey, createClient$1 as createClient, createClient as createHttpClient, createService, defineApi, endpoint, generateHooks, mapKeysDeep, parseWithSchema, resource, snakeToCamelKey, toCamelCase, toSnakeCase };
|
package/dist/sdk.d.ts
CHANGED
|
@@ -121,16 +121,24 @@ type CallOptions<TParams = unknown, TBody = unknown> = {
|
|
|
121
121
|
body?: TBody;
|
|
122
122
|
headers?: Record<string, string>;
|
|
123
123
|
};
|
|
124
|
-
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
124
|
+
type EndpointCallableOptions<TParams, TBody> = (unknown extends TParams ? {
|
|
125
|
+
params?: never;
|
|
126
|
+
} : {
|
|
125
127
|
params: TParams;
|
|
126
128
|
}) & (unknown extends TBody ? {
|
|
127
|
-
body?:
|
|
129
|
+
body?: TBody;
|
|
128
130
|
} : {
|
|
129
131
|
body: TBody;
|
|
130
132
|
}) & {
|
|
131
133
|
query?: Record<string, any>;
|
|
132
134
|
headers?: Record<string, string>;
|
|
133
135
|
};
|
|
136
|
+
type LooseEndpointOptions = {
|
|
137
|
+
params?: unknown;
|
|
138
|
+
query?: Record<string, unknown>;
|
|
139
|
+
body?: unknown;
|
|
140
|
+
headers?: Record<string, string>;
|
|
141
|
+
};
|
|
134
142
|
type RequiredKeys<T> = {
|
|
135
143
|
[K in keyof T]-?: {} extends Pick<T, K> ? never : K;
|
|
136
144
|
}[keyof T];
|
|
@@ -142,7 +150,7 @@ interface ApiError {
|
|
|
142
150
|
}
|
|
143
151
|
interface EndpointCallable<TResponse = unknown, TParams = unknown, TBody = unknown> {
|
|
144
152
|
(...args: OptionalIfEmpty<EndpointCallableOptions<TParams, TBody>>): Promise<TResponse>;
|
|
145
|
-
(options:
|
|
153
|
+
(options: LooseEndpointOptions | undefined): Promise<TResponse>;
|
|
146
154
|
(options: CallOptions<TParams, TBody>): Promise<TResponse>;
|
|
147
155
|
/** Original RouteDefinition — used by useApiQuery / useApiMutation */
|
|
148
156
|
$def: RouteDefinition<TResponse, TParams, TBody>;
|
|
@@ -310,4 +318,4 @@ declare function mapKeysDeep<T>(value: T, keyCase: KeyCase): T;
|
|
|
310
318
|
declare function toCamelCase<T>(value: T): T;
|
|
311
319
|
declare function toSnakeCase<T>(value: T): T;
|
|
312
320
|
|
|
313
|
-
export { type ApiDefinition, type ApiError, type ApiResponse, type CallOptions, type CamelCasedPropertiesDeep, type CamelToSnake, type EndpointCallable, type EndpointCallableOptions, type EndpointDefinition$1 as EndpointDefinition, GenericService, type GenericServiceOptions, type HttpMethod, type Id, type KeyCase, type OptionalIfEmpty, type ParseResult, type ParserSchema, type QueryParams, type ResourceConfig, type ResourceDefinition, type RouteDefinition, type RouteMapper, type RouteParserSchema, type RouteSchema, type RouteSchemaMap, type RouteSchemaValue, type RouteTransform, type RouteTransformMap, type SchemaLike, type ServiceConfig, type SnakeCasedPropertiesDeep, type SnakeToCamel, type UnknownRecord, camelToSnakeKey, createClient$1 as createClient, createClient as createHttpClient, createService, defineApi, endpoint, generateHooks, mapKeysDeep, parseWithSchema, resource, snakeToCamelKey, toCamelCase, toSnakeCase };
|
|
321
|
+
export { type ApiDefinition, type ApiError, type ApiResponse, type CallOptions, type CamelCasedPropertiesDeep, type CamelToSnake, type EndpointCallable, type EndpointCallableOptions, type EndpointDefinition$1 as EndpointDefinition, GenericService, type GenericServiceOptions, type HttpMethod, type Id, type KeyCase, type LooseEndpointOptions, type OptionalIfEmpty, type ParseResult, type ParserSchema, type QueryParams, type ResourceConfig, type ResourceDefinition, type RouteDefinition, type RouteMapper, type RouteParserSchema, type RouteSchema, type RouteSchemaMap, type RouteSchemaValue, type RouteTransform, type RouteTransformMap, type SchemaLike, type ServiceConfig, type SnakeCasedPropertiesDeep, type SnakeToCamel, type UnknownRecord, camelToSnakeKey, createClient$1 as createClient, createClient as createHttpClient, createService, defineApi, endpoint, generateHooks, mapKeysDeep, parseWithSchema, resource, snakeToCamelKey, toCamelCase, toSnakeCase };
|