@asyncapi/converter 0.10.0 → 0.11.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/cli.js +1 -1
- package/lib/convert.js +5 -0
- package/lib/interfaces.d.ts +1 -1
- package/package.json +1 -1
package/cli.js
CHANGED
package/lib/convert.js
CHANGED
|
@@ -27,6 +27,7 @@ const conversions = {
|
|
|
27
27
|
'2.1.0': from__2_0_0__to__2_1_0,
|
|
28
28
|
'2.2.0': from__2_1_0__to__2_2_0,
|
|
29
29
|
'2.3.0': from__2_2_0__to__2_3_0,
|
|
30
|
+
'2.4.0': from__2_3_0__to__2_4_0,
|
|
30
31
|
};
|
|
31
32
|
const conversionVersions = Object.keys(conversions);
|
|
32
33
|
function convert(asyncapi, version, options = {}) {
|
|
@@ -191,3 +192,7 @@ function from__2_2_0__to__2_3_0(asyncapi, _) {
|
|
|
191
192
|
asyncapi.asyncapi = '2.3.0';
|
|
192
193
|
return asyncapi;
|
|
193
194
|
}
|
|
195
|
+
function from__2_3_0__to__2_4_0(asyncapi, _) {
|
|
196
|
+
asyncapi.asyncapi = '2.4.0';
|
|
197
|
+
return asyncapi;
|
|
198
|
+
}
|
package/lib/interfaces.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export declare type AsyncAPIDocument = {
|
|
2
2
|
asyncapi: string;
|
|
3
3
|
} & Record<string, any>;
|
|
4
|
-
export declare type ConvertVersion = '1.1.0' | '1.2.0' | '2.0.0-rc1' | '2.0.0-rc2' | '2.0.0' | '2.1.0' | '2.2.0' | '2.3.0';
|
|
4
|
+
export declare type ConvertVersion = '1.1.0' | '1.2.0' | '2.0.0-rc1' | '2.0.0-rc2' | '2.0.0' | '2.1.0' | '2.2.0' | '2.3.0' | '2.4.0';
|
|
5
5
|
export interface ConvertOptions {
|
|
6
6
|
id?: string;
|
|
7
7
|
}
|