@bitstack/ng-query-codegen-openapi 0.0.30 → 0.0.31-alpha.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/lib/index.d.mts CHANGED
@@ -46,12 +46,12 @@ interface CommonOptions {
46
46
  importName: string;
47
47
  };
48
48
  /**
49
- * HttpClient for WebApiConfiguration import
49
+ * HTTP client configuration for API calls
50
50
  * defaults to { file: "@core/httpClient/webapi/webapi-http-client.providers", importName: "WEBAPI_HTTP_CLIENT" }
51
51
  */
52
52
  httpClient?: {
53
53
  file: string;
54
- importName: string;
54
+ importReturnTypeName: string;
55
55
  };
56
56
  /**
57
57
  * defaults to "enhancedApi"
@@ -71,13 +71,9 @@ interface CommonOptions {
71
71
  operationNameSuffix?: string;
72
72
  /**
73
73
  * defaults to `false`
74
- * `true` will generate hooks for queries and mutations, but no lazyQueries
74
+ * `true` will generate lazy query hooks (useLazy prefix) for query endpoints
75
75
  */
76
- hooks?: boolean | {
77
- queries: boolean;
78
- lazyQueries: boolean;
79
- mutations: boolean;
80
- };
76
+ useLazyQueries?: boolean;
81
77
  /**
82
78
  * defaults to false
83
79
  * `true` will generate a union type for `undefined` properties like: `{ id?: string | undefined }` instead of `{ id?: string }`
@@ -131,11 +127,6 @@ interface CommonOptions {
131
127
  * File path for importing IRestFulEndpointsQueryReturn type
132
128
  */
133
129
  endpointsQueryReturnTypeFile?: string;
134
- /**
135
- * defaults to 60 (seconds)
136
- * Number of seconds to wait before refetching data when component mounts or args change
137
- */
138
- refetchOnMountOrArgChange?: number;
139
130
  }
140
131
  type TextMatcher = string | RegExp | (string | RegExp)[];
141
132
  type EndpointMatcherFunction = (operationName: string, operationDefinition: OperationDefinition) => boolean;
@@ -147,11 +138,6 @@ interface OutputFileOptions extends Partial<CommonOptions> {
147
138
  filterEndpoints?: EndpointMatcher;
148
139
  endpointOverrides?: EndpointOverrides[];
149
140
  queryMatch?: (method: string, path: string) => boolean;
150
- /**
151
- * defaults to false
152
- * If passed as true it will generate TS enums instead of union of strings
153
- */
154
- useEnumType?: boolean;
155
141
  sharedTypesFile?: string;
156
142
  /**
157
143
  * groupKey for service class naming, e.g., "room" -> "RoomService"
package/lib/index.d.ts CHANGED
@@ -46,12 +46,12 @@ interface CommonOptions {
46
46
  importName: string;
47
47
  };
48
48
  /**
49
- * HttpClient for WebApiConfiguration import
49
+ * HTTP client configuration for API calls
50
50
  * defaults to { file: "@core/httpClient/webapi/webapi-http-client.providers", importName: "WEBAPI_HTTP_CLIENT" }
51
51
  */
52
52
  httpClient?: {
53
53
  file: string;
54
- importName: string;
54
+ importReturnTypeName: string;
55
55
  };
56
56
  /**
57
57
  * defaults to "enhancedApi"
@@ -71,13 +71,9 @@ interface CommonOptions {
71
71
  operationNameSuffix?: string;
72
72
  /**
73
73
  * defaults to `false`
74
- * `true` will generate hooks for queries and mutations, but no lazyQueries
74
+ * `true` will generate lazy query hooks (useLazy prefix) for query endpoints
75
75
  */
76
- hooks?: boolean | {
77
- queries: boolean;
78
- lazyQueries: boolean;
79
- mutations: boolean;
80
- };
76
+ useLazyQueries?: boolean;
81
77
  /**
82
78
  * defaults to false
83
79
  * `true` will generate a union type for `undefined` properties like: `{ id?: string | undefined }` instead of `{ id?: string }`
@@ -131,11 +127,6 @@ interface CommonOptions {
131
127
  * File path for importing IRestFulEndpointsQueryReturn type
132
128
  */
133
129
  endpointsQueryReturnTypeFile?: string;
134
- /**
135
- * defaults to 60 (seconds)
136
- * Number of seconds to wait before refetching data when component mounts or args change
137
- */
138
- refetchOnMountOrArgChange?: number;
139
130
  }
140
131
  type TextMatcher = string | RegExp | (string | RegExp)[];
141
132
  type EndpointMatcherFunction = (operationName: string, operationDefinition: OperationDefinition) => boolean;
@@ -147,11 +138,6 @@ interface OutputFileOptions extends Partial<CommonOptions> {
147
138
  filterEndpoints?: EndpointMatcher;
148
139
  endpointOverrides?: EndpointOverrides[];
149
140
  queryMatch?: (method: string, path: string) => boolean;
150
- /**
151
- * defaults to false
152
- * If passed as true it will generate TS enums instead of union of strings
153
- */
154
- useEnumType?: boolean;
155
141
  sharedTypesFile?: string;
156
142
  /**
157
143
  * groupKey for service class naming, e.g., "room" -> "RoomService"