@rxap/open-api 22.0.0-dev.1 → 22.0.0-dev.2
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/CHANGELOG.md +25 -0
- package/README.md +5 -3
- package/compodoc/changelog.html +24 -0
- package/compodoc/dependencies.html +12 -8
- package/compodoc/index.html +4 -3
- package/compodoc/js/search/search_index.js +2 -2
- package/compodoc/llms.txt +3 -1
- package/compodoc/miscellaneous/functions.html +81 -0
- package/compodoc/properties.html +1 -1
- package/docs/documentation.json +176 -152
- package/docs/html/classes/OpenApiConfigService.html +16 -16
- package/docs/html/classes/OpenApiHttpResponseError.html +20 -20
- package/docs/html/classes/RxapOpenApiError.html +18 -18
- package/docs/html/classes/SchemaValidationMixin.html +15 -15
- package/docs/html/functions/AssertOpenApiV3.html +4 -4
- package/docs/html/functions/IsOpenApiV3.html +4 -4
- package/docs/html/functions/IsReferenceObject.html +4 -4
- package/docs/html/functions/NotContainsReferenceObjects.html +4 -4
- package/docs/html/functions/OpenApiInit.html +4 -4
- package/docs/html/functions/getJsonContentSchema.html +4 -4
- package/docs/html/functions/getJsonSchema.html +4 -4
- package/docs/html/functions/hasJsonContentSchema.html +4 -4
- package/docs/html/functions/hasJsonSchema.html +4 -4
- package/docs/html/hierarchy.html +4 -4
- package/docs/html/index.html +8 -7
- package/docs/html/interfaces/OpenApiInitOptions.html +6 -6
- package/docs/html/interfaces/OpenApiMetaData.html +9 -9
- package/docs/html/interfaces/OperationObjectWithMetadata.html +18 -18
- package/docs/html/interfaces/SchemaValidationResponse.html +8 -8
- package/docs/html/modules.html +4 -4
- package/docs/html/types/OperationMap.html +4 -4
- package/docs/html/variables/DEFAULT_OPEN_API_DATA_SOURCE_META_DATA.html +4 -4
- package/docs/html/variables/DEFAULT_OPEN_API_REMOTE_METHOD_META_DATA.html +4 -4
- package/docs/html/variables/DISABLE_SCHEMA_VALIDATION.html +4 -4
- package/docs/html/variables/DISABLE_VALIDATION.html +4 -4
- package/docs/html/variables/OPEN_API_OPERATION.html +4 -4
- package/docs/html/variables/OPEN_API_OPERATION_ID.html +4 -4
- package/docs/html/variables/OPEN_API_SERVER_ID.html +4 -4
- package/docs/html/variables/OPEN_API_SERVER_INDEX.html +4 -4
- package/docs/html/variables/RXAP_OPEN_API_CONFIG.html +4 -4
- package/docs/html/variables/RXAP_OPEN_API_STRICT_VALIDATOR.html +4 -4
- package/docs/html/variables/injectOpenApiBaseUrlHttpInterceptorFn.html +4 -4
- package/docs/markdown/README.md +6 -4
- package/docs/markdown/classes/OpenApiConfigService.md +14 -14
- package/docs/markdown/classes/OpenApiHttpResponseError.md +18 -18
- package/docs/markdown/classes/RxapOpenApiError.md +16 -16
- package/docs/markdown/classes/SchemaValidationMixin.md +13 -13
- package/docs/markdown/functions/AssertOpenApiV3.md +2 -2
- package/docs/markdown/functions/IsOpenApiV3.md +2 -2
- package/docs/markdown/functions/IsReferenceObject.md +2 -2
- package/docs/markdown/functions/NotContainsReferenceObjects.md +2 -2
- package/docs/markdown/functions/OpenApiInit.md +2 -2
- package/docs/markdown/functions/getJsonContentSchema.md +2 -2
- package/docs/markdown/functions/getJsonSchema.md +2 -2
- package/docs/markdown/functions/hasJsonContentSchema.md +2 -2
- package/docs/markdown/functions/hasJsonSchema.md +2 -2
- package/docs/markdown/globals.md +2 -2
- package/docs/markdown/interfaces/OpenApiInitOptions.md +4 -4
- package/docs/markdown/interfaces/OpenApiMetaData.md +7 -7
- package/docs/markdown/interfaces/OperationObjectWithMetadata.md +16 -16
- package/docs/markdown/interfaces/SchemaValidationResponse.md +6 -6
- package/docs/markdown/type-aliases/OperationMap.md +2 -2
- package/docs/markdown/variables/DEFAULT_OPEN_API_DATA_SOURCE_META_DATA.md +2 -2
- package/docs/markdown/variables/DEFAULT_OPEN_API_REMOTE_METHOD_META_DATA.md +2 -2
- package/docs/markdown/variables/DISABLE_SCHEMA_VALIDATION.md +2 -2
- package/docs/markdown/variables/DISABLE_VALIDATION.md +2 -2
- package/docs/markdown/variables/OPEN_API_OPERATION.md +2 -2
- package/docs/markdown/variables/OPEN_API_OPERATION_ID.md +2 -2
- package/docs/markdown/variables/OPEN_API_SERVER_ID.md +2 -2
- package/docs/markdown/variables/OPEN_API_SERVER_INDEX.md +2 -2
- package/docs/markdown/variables/RXAP_OPEN_API_CONFIG.md +2 -2
- package/docs/markdown/variables/RXAP_OPEN_API_STRICT_VALIDATOR.md +2 -2
- package/docs/markdown/variables/injectOpenApiBaseUrlHttpInterceptorFn.md +2 -2
- package/docs/wiki/Class.OpenApiConfigService.md +13 -13
- package/docs/wiki/Class.OpenApiHttpResponseError.md +17 -17
- package/docs/wiki/Class.RxapOpenApiError.md +15 -15
- package/docs/wiki/Class.SchemaValidationMixin.md +12 -12
- package/docs/wiki/Function.AssertOpenApiV3.md +1 -1
- package/docs/wiki/Function.IsOpenApiV3.md +1 -1
- package/docs/wiki/Function.IsReferenceObject.md +1 -1
- package/docs/wiki/Function.NotContainsReferenceObjects.md +1 -1
- package/docs/wiki/Function.OpenApiInit.md +1 -1
- package/docs/wiki/Function.getJsonContentSchema.md +1 -1
- package/docs/wiki/Function.getJsonSchema.md +1 -1
- package/docs/wiki/Function.hasJsonContentSchema.md +1 -1
- package/docs/wiki/Function.hasJsonSchema.md +1 -1
- package/docs/wiki/Home.md +5 -3
- package/docs/wiki/Interface.OpenApiInitOptions.md +3 -3
- package/docs/wiki/Interface.OpenApiMetaData.md +6 -6
- package/docs/wiki/Interface.OperationObjectWithMetadata.md +15 -15
- package/docs/wiki/Interface.SchemaValidationResponse.md +5 -5
- package/docs/wiki/TypeAlias.OperationMap.md +1 -1
- package/docs/wiki/Variable.DEFAULT_OPEN_API_DATA_SOURCE_META_DATA.md +1 -1
- package/docs/wiki/Variable.DEFAULT_OPEN_API_REMOTE_METHOD_META_DATA.md +1 -1
- package/docs/wiki/Variable.DISABLE_SCHEMA_VALIDATION.md +1 -1
- package/docs/wiki/Variable.DISABLE_VALIDATION.md +1 -1
- package/docs/wiki/Variable.OPEN_API_OPERATION.md +1 -1
- package/docs/wiki/Variable.OPEN_API_OPERATION_ID.md +1 -1
- package/docs/wiki/Variable.OPEN_API_SERVER_ID.md +1 -1
- package/docs/wiki/Variable.OPEN_API_SERVER_INDEX.md +1 -1
- package/docs/wiki/Variable.RXAP_OPEN_API_CONFIG.md +1 -1
- package/docs/wiki/Variable.RXAP_OPEN_API_STRICT_VALIDATOR.md +1 -1
- package/docs/wiki/Variable.injectOpenApiBaseUrlHttpInterceptorFn.md +1 -1
- package/docs/wiki/globals.md +1 -1
- package/generators.json +16 -0
- package/package.json +24 -25
- package/src/generators/init/generator.js +120 -0
- package/src/generators/init/index.js +6 -0
- package/src/generators/init/schema.json +8 -0
- package/src/generators/package.json +3 -0
- package/compodoc/js/libs/vis.min.js +0 -47
- package/compodoc/js/menu-wc_es5.js +0 -40
- package/theme.css +0 -1
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
# Interface: OperationObjectWithMetadata
|
|
4
4
|
|
|
5
|
-
Defined in: [packages/angular/open-api/src/lib/open-api.ts:3](https://gitlab.com/rxap/packages/-/blob/
|
|
5
|
+
Defined in: [packages/angular/open-api/src/lib/open-api.ts:3](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/open-api.ts#L3)
|
|
6
6
|
|
|
7
7
|
## Extends
|
|
8
8
|
|
|
@@ -14,7 +14,7 @@ Defined in: [packages/angular/open-api/src/lib/open-api.ts:3](https://gitlab.com
|
|
|
14
14
|
|
|
15
15
|
> `optional` **callbacks?**: `object`
|
|
16
16
|
|
|
17
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:224
|
|
17
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:224
|
|
18
18
|
|
|
19
19
|
#### Index Signature
|
|
20
20
|
|
|
@@ -30,7 +30,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:224
|
|
|
30
30
|
|
|
31
31
|
> `optional` **deprecated?**: `boolean`
|
|
32
32
|
|
|
33
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:227
|
|
33
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:227
|
|
34
34
|
|
|
35
35
|
#### Inherited from
|
|
36
36
|
|
|
@@ -42,7 +42,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:227
|
|
|
42
42
|
|
|
43
43
|
> `optional` **description?**: `string`
|
|
44
44
|
|
|
45
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:218
|
|
45
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:218
|
|
46
46
|
|
|
47
47
|
#### Inherited from
|
|
48
48
|
|
|
@@ -54,7 +54,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:218
|
|
|
54
54
|
|
|
55
55
|
> `optional` **externalDocs?**: `ExternalDocumentationObject`
|
|
56
56
|
|
|
57
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:219
|
|
57
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:219
|
|
58
58
|
|
|
59
59
|
#### Inherited from
|
|
60
60
|
|
|
@@ -66,7 +66,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:219
|
|
|
66
66
|
|
|
67
67
|
> **method**: `string`
|
|
68
68
|
|
|
69
|
-
Defined in: [packages/angular/open-api/src/lib/open-api.ts:5](https://gitlab.com/rxap/packages/-/blob/
|
|
69
|
+
Defined in: [packages/angular/open-api/src/lib/open-api.ts:5](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/open-api.ts#L5)
|
|
70
70
|
|
|
71
71
|
***
|
|
72
72
|
|
|
@@ -74,7 +74,7 @@ Defined in: [packages/angular/open-api/src/lib/open-api.ts:5](https://gitlab.com
|
|
|
74
74
|
|
|
75
75
|
> `optional` **operationId?**: `string`
|
|
76
76
|
|
|
77
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:220
|
|
77
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:220
|
|
78
78
|
|
|
79
79
|
#### Inherited from
|
|
80
80
|
|
|
@@ -86,7 +86,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:220
|
|
|
86
86
|
|
|
87
87
|
> `optional` **parameters?**: (`ReferenceObject` \| `ParameterObject`)[]
|
|
88
88
|
|
|
89
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:221
|
|
89
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:221
|
|
90
90
|
|
|
91
91
|
#### Inherited from
|
|
92
92
|
|
|
@@ -98,7 +98,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:221
|
|
|
98
98
|
|
|
99
99
|
> **path**: `string`
|
|
100
100
|
|
|
101
|
-
Defined in: [packages/angular/open-api/src/lib/open-api.ts:4](https://gitlab.com/rxap/packages/-/blob/
|
|
101
|
+
Defined in: [packages/angular/open-api/src/lib/open-api.ts:4](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/open-api.ts#L4)
|
|
102
102
|
|
|
103
103
|
***
|
|
104
104
|
|
|
@@ -106,7 +106,7 @@ Defined in: [packages/angular/open-api/src/lib/open-api.ts:4](https://gitlab.com
|
|
|
106
106
|
|
|
107
107
|
> `optional` **requestBody?**: `ReferenceObject` \| `RequestBodyObject`
|
|
108
108
|
|
|
109
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:222
|
|
109
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:222
|
|
110
110
|
|
|
111
111
|
#### Inherited from
|
|
112
112
|
|
|
@@ -118,7 +118,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:222
|
|
|
118
118
|
|
|
119
119
|
> **responses**: `ResponsesObject`
|
|
120
120
|
|
|
121
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:223
|
|
121
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:223
|
|
122
122
|
|
|
123
123
|
#### Inherited from
|
|
124
124
|
|
|
@@ -130,7 +130,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:223
|
|
|
130
130
|
|
|
131
131
|
> `optional` **security?**: `SecurityRequirementObject`[]
|
|
132
132
|
|
|
133
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:228
|
|
133
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:228
|
|
134
134
|
|
|
135
135
|
#### Inherited from
|
|
136
136
|
|
|
@@ -142,7 +142,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:228
|
|
|
142
142
|
|
|
143
143
|
> `optional` **servers?**: `ServerObject`[]
|
|
144
144
|
|
|
145
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:229
|
|
145
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:229
|
|
146
146
|
|
|
147
147
|
#### Inherited from
|
|
148
148
|
|
|
@@ -154,7 +154,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:229
|
|
|
154
154
|
|
|
155
155
|
> `optional` **summary?**: `string`
|
|
156
156
|
|
|
157
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:217
|
|
157
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:217
|
|
158
158
|
|
|
159
159
|
#### Inherited from
|
|
160
160
|
|
|
@@ -166,7 +166,7 @@ Defined in: node\_modules/openapi-types/dist/index.d.ts:217
|
|
|
166
166
|
|
|
167
167
|
> `optional` **tags?**: `string`[]
|
|
168
168
|
|
|
169
|
-
Defined in: node\_modules/openapi-types/dist/index.d.ts:216
|
|
169
|
+
Defined in: node\_modules/.pnpm/openapi-types@10.0.0/node\_modules/openapi-types/dist/index.d.ts:216
|
|
170
170
|
|
|
171
171
|
#### Inherited from
|
|
172
172
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
# Interface: SchemaValidationResponse\<Data\>
|
|
4
4
|
|
|
5
|
-
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:24](https://gitlab.com/rxap/packages/-/blob/
|
|
5
|
+
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:24](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L24)
|
|
6
6
|
|
|
7
7
|
## Type Parameters
|
|
8
8
|
|
|
@@ -16,7 +16,7 @@ Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:24](ht
|
|
|
16
16
|
|
|
17
17
|
> `optional` **body?**: `Data` \| `null`
|
|
18
18
|
|
|
19
|
-
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:27](https://gitlab.com/rxap/packages/-/blob/
|
|
19
|
+
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:27](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L27)
|
|
20
20
|
|
|
21
21
|
***
|
|
22
22
|
|
|
@@ -24,7 +24,7 @@ Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:27](ht
|
|
|
24
24
|
|
|
25
25
|
> `optional` **data?**: `Data`
|
|
26
26
|
|
|
27
|
-
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:28](https://gitlab.com/rxap/packages/-/blob/
|
|
27
|
+
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:28](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L28)
|
|
28
28
|
|
|
29
29
|
***
|
|
30
30
|
|
|
@@ -32,7 +32,7 @@ Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:28](ht
|
|
|
32
32
|
|
|
33
33
|
> **headers**: `HttpHeaders`
|
|
34
34
|
|
|
35
|
-
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:25](https://gitlab.com/rxap/packages/-/blob/
|
|
35
|
+
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:25](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L25)
|
|
36
36
|
|
|
37
37
|
***
|
|
38
38
|
|
|
@@ -40,4 +40,4 @@ Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:25](ht
|
|
|
40
40
|
|
|
41
41
|
> **status**: `number`
|
|
42
42
|
|
|
43
|
-
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:26](https://gitlab.com/rxap/packages/-/blob/
|
|
43
|
+
Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:26](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L26)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> **OperationMap** = `Map`\<`string`, [`OperationObjectWithMetadata`](../wiki/Interface.OperationObjectWithMetadata)\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/open-api-config.service.ts:10](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/open-api-config.service.ts:10](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/open-api-config.service.ts#L10)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **DEFAULT\_OPEN\_API\_DATA\_SOURCE\_META\_DATA**: `InjectionToken`\<`unknown`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/tokens.ts:7](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/tokens.ts:7](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/tokens.ts#L7)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **DEFAULT\_OPEN\_API\_REMOTE\_METHOD\_META\_DATA**: `InjectionToken`\<`unknown`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/tokens.ts:5](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/tokens.ts:5](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/tokens.ts#L5)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **DISABLE\_SCHEMA\_VALIDATION**: `InjectionToken`\<`boolean`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/tokens.ts:8](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/tokens.ts:8](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/tokens.ts#L8)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **DISABLE\_VALIDATION**: `InjectionToken`\<`boolean`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/tokens.ts:12](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/tokens.ts:12](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/tokens.ts#L12)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **OPEN\_API\_OPERATION**: `HttpContextToken`\<`string`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:6](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:6](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/http-context-tokens.ts#L6)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **OPEN\_API\_OPERATION\_ID**: `HttpContextToken`\<`string`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:3](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:3](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/http-context-tokens.ts#L3)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **OPEN\_API\_SERVER\_ID**: `HttpContextToken`\<`string` \| `null`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:4](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:4](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/http-context-tokens.ts#L4)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **OPEN\_API\_SERVER\_INDEX**: `HttpContextToken`\<`number`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:5](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/http-context-tokens.ts:5](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/http-context-tokens.ts#L5)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **RXAP\_OPEN\_API\_CONFIG**: `InjectionToken`\<`unknown`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/tokens.ts:3](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/tokens.ts:3](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/tokens.ts#L3)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **RXAP\_OPEN\_API\_STRICT\_VALIDATOR**: `InjectionToken`\<`unknown`\>
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/tokens.ts:4](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/tokens.ts:4](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/tokens.ts#L4)
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
> `const` **injectOpenApiBaseUrlHttpInterceptorFn**: `HttpInterceptorFn`
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/angular/open-api/src/lib/http-interceptors.ts:9](https://gitlab.com/rxap/packages/-/blob/
|
|
7
|
+
Defined in: [packages/angular/open-api/src/lib/http-interceptors.ts:9](https://gitlab.com/rxap/packages/-/blob/73459044d95e79d1cc84f9d21f658812d63c3185/packages/angular/open-api/src/lib/http-interceptors.ts#L9)
|
package/docs/wiki/globals.md
CHANGED
package/generators.json
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"generators": {
|
|
3
|
+
"init": {
|
|
4
|
+
"factory": "./src/generators/init/generator",
|
|
5
|
+
"schema": "./src/generators/init/schema.json",
|
|
6
|
+
"description": "Initialize the package in the workspace"
|
|
7
|
+
}
|
|
8
|
+
},
|
|
9
|
+
"schematics": {
|
|
10
|
+
"init": {
|
|
11
|
+
"factory": "./src/generators/init/index",
|
|
12
|
+
"schema": "./src/generators/init/schema.json",
|
|
13
|
+
"description": "Initialize the package in the workspace"
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "22.0.0-dev.
|
|
2
|
+
"version": "22.0.0-dev.2",
|
|
3
3
|
"name": "@rxap/open-api",
|
|
4
4
|
"description": "This package provides tools for working with OpenAPI specifications in Angular applications. It includes services for configuring and loading OpenAPI definitions, validating requests and responses against schemas, and handling errors. It also offers utilities for building HTTP requests based on OpenAPI definitions.\n",
|
|
5
5
|
"license": "GPL-3.0-or-later",
|
|
@@ -10,14 +10,15 @@
|
|
|
10
10
|
"peerDependencies": {
|
|
11
11
|
"@angular/common": "^22.0.0",
|
|
12
12
|
"@angular/core": "^22.0.0",
|
|
13
|
-
"@rxap/config": "^22.0.0-dev.
|
|
14
|
-
"@rxap/data-source": "^22.0.0-dev.
|
|
15
|
-
"@rxap/environment": "^22.0.0-dev.
|
|
16
|
-
"@rxap/mixin": "^16.0.18-dev.
|
|
17
|
-
"@rxap/
|
|
18
|
-
"@rxap/
|
|
19
|
-
"@rxap/
|
|
20
|
-
"
|
|
13
|
+
"@rxap/config": "^22.0.0-dev.2",
|
|
14
|
+
"@rxap/data-source": "^22.0.0-dev.2",
|
|
15
|
+
"@rxap/environment": "^22.0.0-dev.2",
|
|
16
|
+
"@rxap/mixin": "^16.0.18-dev.1",
|
|
17
|
+
"@rxap/pattern": "^1.1.17-dev.1",
|
|
18
|
+
"@rxap/remote-method": "^22.0.0-dev.2",
|
|
19
|
+
"@rxap/rxjs": "^1.1.19-dev.1",
|
|
20
|
+
"@rxap/utilities": "^16.5.3-dev.1",
|
|
21
|
+
"ajv": "^8.0.0",
|
|
21
22
|
"openapi-types": "^10.0.0",
|
|
22
23
|
"rxjs": "^7.0.0"
|
|
23
24
|
},
|
|
@@ -68,53 +69,52 @@
|
|
|
68
69
|
},
|
|
69
70
|
{
|
|
70
71
|
"package": "@rxap/config",
|
|
71
|
-
"version": "22.0.0-dev.
|
|
72
|
+
"version": "22.0.0-dev.2"
|
|
72
73
|
},
|
|
73
74
|
{
|
|
74
75
|
"package": "@rxap/data-source",
|
|
75
|
-
"version": "22.0.0-dev.
|
|
76
|
+
"version": "22.0.0-dev.2"
|
|
76
77
|
},
|
|
77
78
|
{
|
|
78
79
|
"package": "@rxap/data-structure-tree",
|
|
79
|
-
"version": "1.1.20-dev.
|
|
80
|
+
"version": "1.1.20-dev.1"
|
|
80
81
|
},
|
|
81
82
|
{
|
|
82
83
|
"package": "@rxap/definition",
|
|
83
|
-
"version": "22.0.0-dev.
|
|
84
|
+
"version": "22.0.0-dev.2"
|
|
84
85
|
},
|
|
85
86
|
{
|
|
86
87
|
"package": "@rxap/environment",
|
|
87
|
-
"version": "22.0.0-dev.
|
|
88
|
+
"version": "22.0.0-dev.2"
|
|
88
89
|
},
|
|
89
90
|
{
|
|
90
91
|
"package": "@rxap/mixin",
|
|
91
|
-
"version": "16.0.18-dev.
|
|
92
|
+
"version": "16.0.18-dev.1"
|
|
92
93
|
},
|
|
93
94
|
{
|
|
94
95
|
"package": "@rxap/pattern",
|
|
95
|
-
"version": "1.1.17-dev.
|
|
96
|
+
"version": "1.1.17-dev.1"
|
|
96
97
|
},
|
|
97
98
|
{
|
|
98
99
|
"package": "@rxap/reflect-metadata",
|
|
99
|
-
"version": "1.0.19-dev.
|
|
100
|
+
"version": "1.0.19-dev.1"
|
|
100
101
|
},
|
|
101
102
|
{
|
|
102
103
|
"package": "@rxap/remote-method",
|
|
103
|
-
"version": "22.0.0-dev.
|
|
104
|
+
"version": "22.0.0-dev.2"
|
|
104
105
|
},
|
|
105
106
|
{
|
|
106
107
|
"package": "@rxap/rxjs",
|
|
107
|
-
"version": "1.1.19-dev.
|
|
108
|
+
"version": "1.1.19-dev.1"
|
|
108
109
|
},
|
|
109
110
|
{
|
|
110
111
|
"package": "@rxap/utilities",
|
|
111
|
-
"version": "16.5.3-dev.
|
|
112
|
+
"version": "16.5.3-dev.1"
|
|
112
113
|
}
|
|
113
114
|
]
|
|
114
115
|
},
|
|
115
116
|
"publishConfig": {
|
|
116
|
-
"access": "public"
|
|
117
|
-
"directory": "../../../dist/packages/angular/open-api"
|
|
117
|
+
"access": "public"
|
|
118
118
|
},
|
|
119
119
|
"repository": {
|
|
120
120
|
"type": "git",
|
|
@@ -152,8 +152,7 @@
|
|
|
152
152
|
"./testing": {
|
|
153
153
|
"types": "./types/rxap-open-api-testing.d.ts",
|
|
154
154
|
"default": "./fesm2022/rxap-open-api-testing.mjs"
|
|
155
|
-
}
|
|
156
|
-
"./theme": "./theme.css"
|
|
155
|
+
}
|
|
157
156
|
},
|
|
158
157
|
"type": "module"
|
|
159
|
-
}
|
|
158
|
+
}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.initGenerator = initGenerator;
|
|
4
|
+
const devkit_1 = require("@nx/devkit");
|
|
5
|
+
const fs_1 = require("fs");
|
|
6
|
+
const path_1 = require("path");
|
|
7
|
+
/**
|
|
8
|
+
* Resolves the directory of a package installed in the workspace. The lookup starts at the
|
|
9
|
+
* workspace root, not at this package: with an isolated node_modules layout (pnpm) or Yarn PnP
|
|
10
|
+
* the peer is not resolvable from here. The plain node_modules path is the fallback for packages
|
|
11
|
+
* whose `exports` map hides their package.json.
|
|
12
|
+
*/
|
|
13
|
+
function resolvePackageDir(root, packageName) {
|
|
14
|
+
try {
|
|
15
|
+
return (0, path_1.dirname)(require.resolve(`${packageName}/package.json`, { paths: [root] }));
|
|
16
|
+
}
|
|
17
|
+
catch {
|
|
18
|
+
return (0, path_1.join)(root, 'node_modules', ...packageName.split('/'));
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
async function initGenerator(tree, options) {
|
|
22
|
+
// The package's own package.json lives on disk next to the compiled generator
|
|
23
|
+
// (inside node_modules when installed), which the virtual Tree does not track.
|
|
24
|
+
// Read it directly from the physical filesystem.
|
|
25
|
+
const packageJsonFilePath = (0, path_1.join)(__dirname, '..', '..', '..', 'package.json');
|
|
26
|
+
if (!(0, fs_1.existsSync)(packageJsonFilePath)) {
|
|
27
|
+
console.error('package.json not found in: ' + packageJsonFilePath);
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
const { peerDependencies, name: packageName } = JSON.parse((0, fs_1.readFileSync)(packageJsonFilePath, 'utf-8'));
|
|
31
|
+
console.log(`Coerce peer dependencies for package: ${packageName}`);
|
|
32
|
+
if (!peerDependencies || !Object.keys(peerDependencies).length) {
|
|
33
|
+
console.log('No peer dependencies found');
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
console.log(`Peer dependencies: ${Object.keys(peerDependencies).join(', ')}`);
|
|
37
|
+
const rootPackageJson = JSON.parse(tree.read('package.json', 'utf-8'));
|
|
38
|
+
let isDevDependency = !!rootPackageJson.devDependencies?.[packageName];
|
|
39
|
+
if (isDevDependency &&
|
|
40
|
+
[/^@rxap\/ngx/, /^@rxap\/nest/].some((rx) => rx.test(packageName))) {
|
|
41
|
+
rootPackageJson.dependencies ??= {};
|
|
42
|
+
rootPackageJson.dependencies[packageName] =
|
|
43
|
+
rootPackageJson.devDependencies[packageName];
|
|
44
|
+
delete rootPackageJson.devDependencies[packageName];
|
|
45
|
+
isDevDependency = false;
|
|
46
|
+
tree.write('package.json', JSON.stringify(rootPackageJson, null, 2));
|
|
47
|
+
}
|
|
48
|
+
if (!isDevDependency &&
|
|
49
|
+
[
|
|
50
|
+
/^@rxap\/plugin/,
|
|
51
|
+
/^@rxap\/workspace/,
|
|
52
|
+
/@rxap\/schematic/,
|
|
53
|
+
].some((rx) => rx.test(packageName))) {
|
|
54
|
+
rootPackageJson.devDependencies ??= {};
|
|
55
|
+
rootPackageJson.devDependencies[packageName] =
|
|
56
|
+
rootPackageJson.dependencies[packageName];
|
|
57
|
+
delete rootPackageJson.dependencies[packageName];
|
|
58
|
+
isDevDependency = true;
|
|
59
|
+
tree.write('package.json', JSON.stringify(rootPackageJson, null, 2));
|
|
60
|
+
}
|
|
61
|
+
const missingPeerDependencies = Object.entries(peerDependencies)
|
|
62
|
+
.filter(([dep]) => !rootPackageJson.dependencies?.[dep] &&
|
|
63
|
+
!rootPackageJson.devDependencies?.[dep])
|
|
64
|
+
.reduce((acc, [dep, version]) => ({ ...acc, [dep]: version }), {});
|
|
65
|
+
if (!Object.keys(missingPeerDependencies).length) {
|
|
66
|
+
console.log('No missing peer dependencies');
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
if (isDevDependency) {
|
|
70
|
+
(0, devkit_1.addDependenciesToPackageJson)(tree, {}, missingPeerDependencies);
|
|
71
|
+
}
|
|
72
|
+
else {
|
|
73
|
+
(0, devkit_1.addDependenciesToPackageJson)(tree, missingPeerDependencies, {});
|
|
74
|
+
}
|
|
75
|
+
await (0, devkit_1.formatFiles)(tree);
|
|
76
|
+
(0, devkit_1.installPackagesTask)(tree);
|
|
77
|
+
for (const peer of Object.keys(missingPeerDependencies)) {
|
|
78
|
+
console.log(`Peer dependency ${peer} added to package.json`);
|
|
79
|
+
// node_modules is physical and excluded from the virtual Tree, so read the
|
|
80
|
+
// peer files from disk.
|
|
81
|
+
const peerPackageDir = resolvePackageDir(tree.root, peer);
|
|
82
|
+
const peerPackageJsonFilePath = (0, path_1.join)(peerPackageDir, 'package.json');
|
|
83
|
+
if (!(0, fs_1.existsSync)(peerPackageJsonFilePath)) {
|
|
84
|
+
console.log(`Peer dependency ${peer} has no package.json`);
|
|
85
|
+
continue;
|
|
86
|
+
}
|
|
87
|
+
const { generators, schematics } = JSON.parse((0, fs_1.readFileSync)(peerPackageJsonFilePath, 'utf-8'));
|
|
88
|
+
if (!generators && !schematics) {
|
|
89
|
+
console.log(`Peer dependency ${peer} has no generators or schematics`);
|
|
90
|
+
continue;
|
|
91
|
+
}
|
|
92
|
+
const configFile = generators || schematics;
|
|
93
|
+
const configFilePath = (0, path_1.join)(peerPackageDir, configFile);
|
|
94
|
+
if (!(0, fs_1.existsSync)(configFilePath)) {
|
|
95
|
+
console.log(`Peer dependency ${peer} has no generators or schematics file`);
|
|
96
|
+
continue;
|
|
97
|
+
}
|
|
98
|
+
const config = JSON.parse((0, fs_1.readFileSync)(configFilePath, 'utf-8'));
|
|
99
|
+
if (!config.generators?.init) {
|
|
100
|
+
console.log(`Peer dependency ${peer} has no init generator`);
|
|
101
|
+
continue;
|
|
102
|
+
}
|
|
103
|
+
const initGeneratorFilePath = config.generators.init.factory;
|
|
104
|
+
const fullInitGeneratorFilePath = (0, path_1.join)(peerPackageDir, initGeneratorFilePath) + '.js';
|
|
105
|
+
if (!(0, fs_1.existsSync)(fullInitGeneratorFilePath)) {
|
|
106
|
+
console.log(`Peer dependency ${peer} has no init generator file: ` +
|
|
107
|
+
fullInitGeneratorFilePath);
|
|
108
|
+
continue;
|
|
109
|
+
}
|
|
110
|
+
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
111
|
+
const initGenerator = require((0, path_1.join)(peerPackageDir, initGeneratorFilePath))?.default;
|
|
112
|
+
if (typeof initGenerator !== 'function') {
|
|
113
|
+
console.log(`Peer dependency ${peer} has no init generator function`);
|
|
114
|
+
continue;
|
|
115
|
+
}
|
|
116
|
+
console.log(`Run init generator for peer dependency ${peer}`);
|
|
117
|
+
await initGenerator(tree, options);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
exports.default = initGenerator;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const devkit_1 = require("@nx/devkit");
|
|
4
|
+
const generator_1 = require("./generator");
|
|
5
|
+
const schematic = (0, devkit_1.convertNxGenerator)(generator_1.default);
|
|
6
|
+
exports.default = schematic;
|