ajsc 5.2.4 → 7.1.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/CHANGELOG.md +103 -0
- package/README.md +303 -144
- package/dist/converter/BaseConverter.d.ts +315 -0
- package/dist/converter/BaseConverter.js +131 -0
- package/dist/converter/BaseConverter.js.map +1 -0
- package/dist/converter/Emitter.d.ts +35 -0
- package/dist/converter/Emitter.js +50 -0
- package/dist/converter/Emitter.js.map +1 -0
- package/dist/converter/discriminatedUnions.d.ts +47 -0
- package/dist/converter/discriminatedUnions.js +168 -0
- package/dist/converter/discriminatedUnions.js.map +1 -0
- package/dist/converter/formatDefault.d.ts +20 -0
- package/dist/converter/formatDefault.js +31 -0
- package/dist/converter/formatDefault.js.map +1 -0
- package/dist/converter/index.d.ts +24 -0
- package/dist/converter/index.js +24 -0
- package/dist/converter/index.js.map +1 -0
- package/dist/converter/mergeUnions.d.ts +36 -0
- package/dist/converter/mergeUnions.js +189 -0
- package/dist/converter/mergeUnions.js.map +1 -0
- package/dist/converter/naming.d.ts +29 -0
- package/dist/converter/naming.js +137 -0
- package/dist/converter/naming.js.map +1 -0
- package/dist/converter/registry.d.ts +18 -0
- package/dist/converter/registry.js +50 -0
- package/dist/converter/registry.js.map +1 -0
- package/dist/converter/walk.d.ts +9 -0
- package/dist/converter/walk.js +40 -0
- package/dist/converter/walk.js.map +1 -0
- package/dist/index.d.ts +71 -3
- package/dist/index.js +63 -3
- package/dist/index.js.map +1 -1
- package/dist/{JSONSchemaConverter.d.ts → ir/JSONSchemaConverter.d.ts} +1 -1
- package/dist/{JSONSchemaConverter.js → ir/JSONSchemaConverter.js} +9 -3
- package/dist/ir/JSONSchemaConverter.js.map +1 -0
- package/dist/ir/index.d.ts +1 -0
- package/dist/ir/index.js +2 -0
- package/dist/ir/index.js.map +1 -0
- package/dist/kotlin/KotlinBaseConverter.d.ts +18 -0
- package/dist/kotlin/KotlinBaseConverter.js +36 -0
- package/dist/kotlin/KotlinBaseConverter.js.map +1 -0
- package/dist/kotlin/KotlinConverter.d.ts +67 -0
- package/dist/kotlin/KotlinConverter.js +142 -0
- package/dist/kotlin/KotlinConverter.js.map +1 -0
- package/dist/kotlin/annotations.d.ts +26 -0
- package/dist/kotlin/annotations.js +35 -0
- package/dist/kotlin/annotations.js.map +1 -0
- package/dist/kotlin/enums.d.ts +15 -0
- package/dist/kotlin/enums.js +58 -0
- package/dist/kotlin/enums.js.map +1 -0
- package/dist/kotlin/index.d.ts +13 -0
- package/dist/kotlin/index.js +14 -0
- package/dist/kotlin/index.js.map +1 -0
- package/dist/kotlin/objectEmitter.d.ts +12 -0
- package/dist/kotlin/objectEmitter.js +74 -0
- package/dist/kotlin/objectEmitter.js.map +1 -0
- package/dist/kotlin/sealedUnion.d.ts +17 -0
- package/dist/kotlin/sealedUnion.js +74 -0
- package/dist/kotlin/sealedUnion.js.map +1 -0
- package/dist/kotlin/typeMapper.d.ts +17 -0
- package/dist/kotlin/typeMapper.js +107 -0
- package/dist/kotlin/typeMapper.js.map +1 -0
- package/dist/kotlin/unsupported.d.ts +13 -0
- package/dist/kotlin/unsupported.js +53 -0
- package/dist/kotlin/unsupported.js.map +1 -0
- package/dist/swift/SwiftBaseConverter.d.ts +18 -0
- package/dist/swift/SwiftBaseConverter.js +38 -0
- package/dist/swift/SwiftBaseConverter.js.map +1 -0
- package/dist/swift/SwiftConverter.d.ts +60 -0
- package/dist/swift/SwiftConverter.js +113 -0
- package/dist/swift/SwiftConverter.js.map +1 -0
- package/dist/swift/discriminatedEnum.d.ts +18 -0
- package/dist/swift/discriminatedEnum.js +99 -0
- package/dist/swift/discriminatedEnum.js.map +1 -0
- package/dist/swift/enums.d.ts +15 -0
- package/dist/swift/enums.js +62 -0
- package/dist/swift/enums.js.map +1 -0
- package/dist/swift/index.d.ts +13 -0
- package/dist/swift/index.js +14 -0
- package/dist/swift/index.js.map +1 -0
- package/dist/swift/structEmitter.d.ts +12 -0
- package/dist/swift/structEmitter.js +70 -0
- package/dist/swift/structEmitter.js.map +1 -0
- package/dist/swift/typeMapper.d.ts +18 -0
- package/dist/swift/typeMapper.js +106 -0
- package/dist/swift/typeMapper.js.map +1 -0
- package/dist/swift/unsupported.d.ts +19 -0
- package/dist/swift/unsupported.js +88 -0
- package/dist/swift/unsupported.js.map +1 -0
- package/dist/typescript/TypescriptBaseConverter.d.ts +25 -0
- package/dist/typescript/TypescriptBaseConverter.js +178 -0
- package/dist/typescript/TypescriptBaseConverter.js.map +1 -0
- package/dist/typescript/TypescriptConverter.d.ts +74 -0
- package/dist/typescript/TypescriptConverter.js +254 -0
- package/dist/typescript/TypescriptConverter.js.map +1 -0
- package/dist/typescript/index.d.ts +12 -0
- package/dist/typescript/index.js +13 -0
- package/dist/typescript/index.js.map +1 -0
- package/dist/utils/index.d.ts +2 -0
- package/dist/utils/index.js +3 -0
- package/dist/utils/index.js.map +1 -0
- package/package.json +39 -6
- package/dist/JSONSchemaConverter.js.map +0 -1
- package/dist/JSONSchemaConverter.test.d.ts +0 -1
- package/dist/JSONSchemaConverter.test.js +0 -585
- package/dist/JSONSchemaConverter.test.js.map +0 -1
- package/dist/Typebox.test.d.ts +0 -1
- package/dist/Typebox.test.js +0 -88
- package/dist/Typebox.test.js.map +0 -1
- package/dist/TypescriptBaseConverter.d.ts +0 -75
- package/dist/TypescriptBaseConverter.js +0 -321
- package/dist/TypescriptBaseConverter.js.map +0 -1
- package/dist/TypescriptConverter.additionalProperties.test.d.ts +0 -1
- package/dist/TypescriptConverter.additionalProperties.test.js +0 -110
- package/dist/TypescriptConverter.additionalProperties.test.js.map +0 -1
- package/dist/TypescriptConverter.arrays.test.d.ts +0 -1
- package/dist/TypescriptConverter.arrays.test.js +0 -130
- package/dist/TypescriptConverter.arrays.test.js.map +0 -1
- package/dist/TypescriptConverter.composites.advanced.test.d.ts +0 -1
- package/dist/TypescriptConverter.composites.advanced.test.js +0 -1070
- package/dist/TypescriptConverter.composites.advanced.test.js.map +0 -1
- package/dist/TypescriptConverter.composites.test.d.ts +0 -1
- package/dist/TypescriptConverter.composites.test.js +0 -335
- package/dist/TypescriptConverter.composites.test.js.map +0 -1
- package/dist/TypescriptConverter.d.ts +0 -163
- package/dist/TypescriptConverter.js +0 -606
- package/dist/TypescriptConverter.js.map +0 -1
- package/dist/TypescriptConverter.jsdoc.test.d.ts +0 -1
- package/dist/TypescriptConverter.jsdoc.test.js +0 -194
- package/dist/TypescriptConverter.jsdoc.test.js.map +0 -1
- package/dist/TypescriptConverter.objects.test.d.ts +0 -1
- package/dist/TypescriptConverter.objects.test.js +0 -258
- package/dist/TypescriptConverter.objects.test.js.map +0 -1
- package/dist/TypescriptConverter.options.test.d.ts +0 -1
- package/dist/TypescriptConverter.options.test.js +0 -501
- package/dist/TypescriptConverter.options.test.js.map +0 -1
- package/dist/TypescriptConverter.primitives.test.d.ts +0 -1
- package/dist/TypescriptConverter.primitives.test.js +0 -26
- package/dist/TypescriptConverter.primitives.test.js.map +0 -1
- package/dist/utils/path-utils.test.d.ts +0 -1
- package/dist/utils/path-utils.test.js +0 -92
- package/dist/utils/path-utils.test.js.map +0 -1
|
@@ -1,194 +0,0 @@
|
|
|
1
|
-
import { describe, it, expect } from "vitest";
|
|
2
|
-
import { TypescriptConverter } from "./TypescriptConverter.js";
|
|
3
|
-
describe("TypescriptConverter - JSDoc emission", () => {
|
|
4
|
-
it("should not emit JSDoc by default", () => {
|
|
5
|
-
const result = new TypescriptConverter({
|
|
6
|
-
type: "object",
|
|
7
|
-
description: "A person",
|
|
8
|
-
properties: {
|
|
9
|
-
name: { type: "string", description: "The name" },
|
|
10
|
-
},
|
|
11
|
-
});
|
|
12
|
-
expect(result.code).not.toContain("/**");
|
|
13
|
-
});
|
|
14
|
-
it("should emit JSDoc on root type description", () => {
|
|
15
|
-
const result = new TypescriptConverter({
|
|
16
|
-
type: "object",
|
|
17
|
-
description: "A person record",
|
|
18
|
-
properties: {
|
|
19
|
-
name: { type: "string" },
|
|
20
|
-
},
|
|
21
|
-
}, { jsdoc: true });
|
|
22
|
-
expect(result.code).toContain("/** A person record */\nexport type Root =");
|
|
23
|
-
});
|
|
24
|
-
it("should emit JSDoc on properties with descriptions", () => {
|
|
25
|
-
const result = new TypescriptConverter({
|
|
26
|
-
type: "object",
|
|
27
|
-
properties: {
|
|
28
|
-
name: { type: "string", description: "The person's name" },
|
|
29
|
-
age: { type: "number" },
|
|
30
|
-
},
|
|
31
|
-
}, { jsdoc: true });
|
|
32
|
-
expect(result.code).toContain("/** The person's name */");
|
|
33
|
-
expect(result.code).toContain("name?:");
|
|
34
|
-
// age has no description, so no JSDoc for it
|
|
35
|
-
expect(result.code).not.toContain("/** age");
|
|
36
|
-
});
|
|
37
|
-
it("should use multiline format when any property has description", () => {
|
|
38
|
-
const result = new TypescriptConverter({
|
|
39
|
-
type: "object",
|
|
40
|
-
properties: {
|
|
41
|
-
name: { type: "string", description: "The name" },
|
|
42
|
-
age: { type: "number" },
|
|
43
|
-
},
|
|
44
|
-
}, { jsdoc: true });
|
|
45
|
-
// Should be multiline with indentation
|
|
46
|
-
expect(result.code).toContain(" /** The name */\n name?:");
|
|
47
|
-
expect(result.code).toContain(" age?:");
|
|
48
|
-
});
|
|
49
|
-
it("should emit JSDoc on extracted/referenced types", () => {
|
|
50
|
-
const result = new TypescriptConverter({
|
|
51
|
-
type: "object",
|
|
52
|
-
properties: {
|
|
53
|
-
address: {
|
|
54
|
-
type: "object",
|
|
55
|
-
description: "The mailing address",
|
|
56
|
-
properties: {
|
|
57
|
-
street: { type: "string" },
|
|
58
|
-
},
|
|
59
|
-
},
|
|
60
|
-
},
|
|
61
|
-
}, { jsdoc: true });
|
|
62
|
-
expect(result.code).toContain("/** The mailing address */\nexport type Address =");
|
|
63
|
-
});
|
|
64
|
-
it("should emit JSDoc on enum declarations", () => {
|
|
65
|
-
const result = new TypescriptConverter({
|
|
66
|
-
type: "object",
|
|
67
|
-
properties: {
|
|
68
|
-
status: {
|
|
69
|
-
type: "string",
|
|
70
|
-
enum: ["active", "inactive"],
|
|
71
|
-
description: "The current status",
|
|
72
|
-
},
|
|
73
|
-
},
|
|
74
|
-
}, { jsdoc: true, enumStyle: "enum" });
|
|
75
|
-
expect(result.code).toContain("/** The current status */\nexport enum Status");
|
|
76
|
-
});
|
|
77
|
-
it("should handle multiline descriptions", () => {
|
|
78
|
-
const result = new TypescriptConverter({
|
|
79
|
-
type: "object",
|
|
80
|
-
description: "Line one\nLine two",
|
|
81
|
-
properties: {
|
|
82
|
-
name: { type: "string" },
|
|
83
|
-
},
|
|
84
|
-
}, { jsdoc: true });
|
|
85
|
-
expect(result.code).toContain("/**\n * Line one\n * Line two\n */");
|
|
86
|
-
});
|
|
87
|
-
it("should not emit JSDoc in inline mode even with jsdoc option", () => {
|
|
88
|
-
const result = new TypescriptConverter({
|
|
89
|
-
type: "object",
|
|
90
|
-
description: "A person",
|
|
91
|
-
properties: {
|
|
92
|
-
name: { type: "string", description: "The name" },
|
|
93
|
-
},
|
|
94
|
-
}, { jsdoc: true, inlineTypes: true });
|
|
95
|
-
expect(result.code).not.toContain("/**");
|
|
96
|
-
});
|
|
97
|
-
it("should keep compact format when no descriptions exist", () => {
|
|
98
|
-
const result = new TypescriptConverter({
|
|
99
|
-
type: "object",
|
|
100
|
-
properties: {
|
|
101
|
-
name: { type: "string" },
|
|
102
|
-
age: { type: "number" },
|
|
103
|
-
},
|
|
104
|
-
}, { jsdoc: true });
|
|
105
|
-
// No descriptions on properties, so should remain compact
|
|
106
|
-
expect(result.code).toContain("{ name?: string; age?: number; }");
|
|
107
|
-
});
|
|
108
|
-
it("should emit JSDoc on properties inside extracted types", () => {
|
|
109
|
-
const result = new TypescriptConverter({
|
|
110
|
-
type: "object",
|
|
111
|
-
properties: {
|
|
112
|
-
user: {
|
|
113
|
-
type: "object",
|
|
114
|
-
properties: {
|
|
115
|
-
email: {
|
|
116
|
-
type: "string",
|
|
117
|
-
description: "User email address",
|
|
118
|
-
},
|
|
119
|
-
name: { type: "string" },
|
|
120
|
-
},
|
|
121
|
-
},
|
|
122
|
-
},
|
|
123
|
-
}, { jsdoc: true });
|
|
124
|
-
// The extracted type should have JSDoc on its property
|
|
125
|
-
expect(result.code).toContain("/** User email address */");
|
|
126
|
-
expect(result.code).toContain("email?:");
|
|
127
|
-
// Verify it's inside the extracted type declaration
|
|
128
|
-
expect(result.code).toMatch(/export type User = \{\n\s+\/\*\* User email address \*\/\n\s+email\?:/);
|
|
129
|
-
});
|
|
130
|
-
it("should emit JSDoc on multiline property descriptions", () => {
|
|
131
|
-
const result = new TypescriptConverter({
|
|
132
|
-
type: "object",
|
|
133
|
-
properties: {
|
|
134
|
-
name: {
|
|
135
|
-
type: "string",
|
|
136
|
-
description: "The full name\nFirst and last",
|
|
137
|
-
},
|
|
138
|
-
},
|
|
139
|
-
}, { jsdoc: true });
|
|
140
|
-
expect(result.code).toContain("/**\n * The full name\n * First and last\n */");
|
|
141
|
-
});
|
|
142
|
-
it("should sanitize */ in descriptions to prevent broken JSDoc", () => {
|
|
143
|
-
const result = new TypescriptConverter({
|
|
144
|
-
type: "object",
|
|
145
|
-
properties: {
|
|
146
|
-
ratio: {
|
|
147
|
-
type: "string",
|
|
148
|
-
description: "use a*/b syntax",
|
|
149
|
-
},
|
|
150
|
-
},
|
|
151
|
-
}, { jsdoc: true });
|
|
152
|
-
// Should escape */ to prevent premature comment close
|
|
153
|
-
expect(result.code).toContain("a*\\/b");
|
|
154
|
-
expect(result.code).not.toMatch(/\/\*\*.*\*\/.*\*\//s);
|
|
155
|
-
});
|
|
156
|
-
it("should emit property title as JSDoc when no description exists", () => {
|
|
157
|
-
const result = new TypescriptConverter({
|
|
158
|
-
type: "object",
|
|
159
|
-
properties: {
|
|
160
|
-
email: { type: "string", title: "Email Address" },
|
|
161
|
-
},
|
|
162
|
-
}, { jsdoc: true });
|
|
163
|
-
expect(result.code).toContain("/** Email Address */");
|
|
164
|
-
expect(result.code).toContain("email?:");
|
|
165
|
-
});
|
|
166
|
-
it("should combine title and description in property JSDoc", () => {
|
|
167
|
-
const result = new TypescriptConverter({
|
|
168
|
-
type: "object",
|
|
169
|
-
properties: {
|
|
170
|
-
email: {
|
|
171
|
-
type: "string",
|
|
172
|
-
title: "Email Address",
|
|
173
|
-
description: "The primary contact email",
|
|
174
|
-
},
|
|
175
|
-
},
|
|
176
|
-
}, { jsdoc: true });
|
|
177
|
-
// Title should appear as a heading, followed by description
|
|
178
|
-
expect(result.code).toContain("Email Address");
|
|
179
|
-
expect(result.code).toContain("The primary contact email");
|
|
180
|
-
});
|
|
181
|
-
it("should not emit root title as JSDoc on type declaration (redundant with type name)", () => {
|
|
182
|
-
const result = new TypescriptConverter({
|
|
183
|
-
type: "object",
|
|
184
|
-
title: "UserProfile",
|
|
185
|
-
properties: {
|
|
186
|
-
name: { type: "string" },
|
|
187
|
-
},
|
|
188
|
-
}, { jsdoc: true });
|
|
189
|
-
// Title matches type name — no JSDoc emitted for root
|
|
190
|
-
expect(result.code).not.toContain("/** UserProfile */");
|
|
191
|
-
expect(result.code).toContain("export type UserProfile =");
|
|
192
|
-
});
|
|
193
|
-
});
|
|
194
|
-
//# sourceMappingURL=TypescriptConverter.jsdoc.test.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TypescriptConverter.jsdoc.test.js","sourceRoot":"","sources":["../src/TypescriptConverter.jsdoc.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAC9C,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAE/D,QAAQ,CAAC,sCAAsC,EAAE,GAAG,EAAE;IACpD,EAAE,CAAC,kCAAkC,EAAE,GAAG,EAAE;QAC1C,MAAM,MAAM,GAAG,IAAI,mBAAmB,CAAC;YACrC,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,UAAU;YACvB,UAAU,EAAE;gBACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ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AA2B,CAAC,CAAC;IAC7D,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,oFAAoF,EAAE,GAAG,EAAE;QAC5F,MAAM,MAAM,GAAG,IAAI,mBAAmB,CACpC;YACE,IAAI,EAAE,QAAQ;YACd,KAAK,EAAE,aAAa;YACpB,UAAU,EAAE;gBACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;aACzB;SACF,EACD,EAAE,KAAK,EAAE,IAAI,EAAE,CAChB,CAAC;QACF,sDAAsD;QACtD,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,SAAS,CAAC,oBAAoB,CAAC,CAAC;QACxD,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,SAAS,CAAC,2BAA2B,CAAC,CAAC;IAC7D,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,258 +0,0 @@
|
|
|
1
|
-
import { describe, it, expect } from "vitest";
|
|
2
|
-
import { TypescriptConverter } from "./TypescriptConverter.js";
|
|
3
|
-
describe("TypescriptConverter - objects (inlineTypes)", () => {
|
|
4
|
-
it("should convert objects", () => {
|
|
5
|
-
expect(new TypescriptConverter({
|
|
6
|
-
type: "object",
|
|
7
|
-
properties: {
|
|
8
|
-
title: { type: "string" },
|
|
9
|
-
year: { type: "number" },
|
|
10
|
-
},
|
|
11
|
-
required: ["title"],
|
|
12
|
-
}).code).toMatch(`{ title: string; year?: number; }`);
|
|
13
|
-
});
|
|
14
|
-
it("should convert a simple JSON schema to Typescript", () => {
|
|
15
|
-
expect(new TypescriptConverter({
|
|
16
|
-
type: "object",
|
|
17
|
-
properties: {
|
|
18
|
-
name: { type: "string" },
|
|
19
|
-
age: { type: "number" },
|
|
20
|
-
contacts: {
|
|
21
|
-
type: "array",
|
|
22
|
-
items: {
|
|
23
|
-
type: "object",
|
|
24
|
-
properties: {
|
|
25
|
-
email: { type: "string" },
|
|
26
|
-
},
|
|
27
|
-
required: ["email"],
|
|
28
|
-
},
|
|
29
|
-
},
|
|
30
|
-
profile: {
|
|
31
|
-
type: "object",
|
|
32
|
-
properties: {
|
|
33
|
-
email: { type: "string" },
|
|
34
|
-
},
|
|
35
|
-
required: ["email"],
|
|
36
|
-
},
|
|
37
|
-
},
|
|
38
|
-
required: ["name", "age"],
|
|
39
|
-
}, {
|
|
40
|
-
inlineTypes: true,
|
|
41
|
-
}).code.replace(/\s/g, "")).toMatch(`{
|
|
42
|
-
name: string;
|
|
43
|
-
age: number;
|
|
44
|
-
contacts?: Array<{ email: string; }>;
|
|
45
|
-
profile?: { email: string; };
|
|
46
|
-
}`.replace(/\s/g, ""));
|
|
47
|
-
});
|
|
48
|
-
it("should convert a named JSON schema top-level object to Typescript", () => {
|
|
49
|
-
expect(new TypescriptConverter({
|
|
50
|
-
$schema: "http://json-schema.org/draft-07/schema#",
|
|
51
|
-
title: "Person",
|
|
52
|
-
type: "object",
|
|
53
|
-
properties: {
|
|
54
|
-
name: { type: "string" },
|
|
55
|
-
age: { type: "number" },
|
|
56
|
-
contacts: {
|
|
57
|
-
type: "array",
|
|
58
|
-
items: {
|
|
59
|
-
type: "object",
|
|
60
|
-
properties: {
|
|
61
|
-
email: { type: "string" },
|
|
62
|
-
},
|
|
63
|
-
required: ["email"],
|
|
64
|
-
},
|
|
65
|
-
},
|
|
66
|
-
profile: {
|
|
67
|
-
type: "object",
|
|
68
|
-
properties: {
|
|
69
|
-
email: { type: "string" },
|
|
70
|
-
},
|
|
71
|
-
required: ["email"],
|
|
72
|
-
},
|
|
73
|
-
},
|
|
74
|
-
required: ["name", "age"],
|
|
75
|
-
}, {
|
|
76
|
-
inlineTypes: true,
|
|
77
|
-
}).code.replace(/\s/g, "")).toEqual(`{ name: string; age: number; contacts?: Array<{ email: string; }>; profile?: { email: string; }; }`.replace(/\s/g, ""));
|
|
78
|
-
});
|
|
79
|
-
it("should convert JSON schema with top-level re-used objects in Typescript", async () => {
|
|
80
|
-
expect(new TypescriptConverter({
|
|
81
|
-
$schema: "http://json-schema.org/draft-07/schema#",
|
|
82
|
-
title: "Person",
|
|
83
|
-
type: "object",
|
|
84
|
-
properties: {
|
|
85
|
-
contacts: {
|
|
86
|
-
type: "array",
|
|
87
|
-
items: {
|
|
88
|
-
type: "object",
|
|
89
|
-
properties: {
|
|
90
|
-
email: { type: "string" },
|
|
91
|
-
},
|
|
92
|
-
required: ["email"],
|
|
93
|
-
},
|
|
94
|
-
},
|
|
95
|
-
profile: {
|
|
96
|
-
type: "object",
|
|
97
|
-
properties: {
|
|
98
|
-
email: { type: "string" },
|
|
99
|
-
},
|
|
100
|
-
required: ["email"],
|
|
101
|
-
},
|
|
102
|
-
contact: {
|
|
103
|
-
type: "object",
|
|
104
|
-
properties: {
|
|
105
|
-
email: { type: "string" },
|
|
106
|
-
},
|
|
107
|
-
required: ["email"],
|
|
108
|
-
},
|
|
109
|
-
email: {
|
|
110
|
-
type: "object",
|
|
111
|
-
properties: {
|
|
112
|
-
email: { type: "string" },
|
|
113
|
-
},
|
|
114
|
-
required: ["email"],
|
|
115
|
-
},
|
|
116
|
-
},
|
|
117
|
-
required: ["name", "age"],
|
|
118
|
-
}, {
|
|
119
|
-
inlineTypes: true,
|
|
120
|
-
}).code.replace(/\s/g, "")).toEqual(`{contacts?:Array<{email:string;}>;profile?:{email:string;};contact?:{email:string;};email?:{email:string;};}`.replace(/\s/g, ""));
|
|
121
|
-
});
|
|
122
|
-
it("should render never type for boolean schema false", () => {
|
|
123
|
-
expect(new TypescriptConverter({
|
|
124
|
-
type: "object",
|
|
125
|
-
properties: {
|
|
126
|
-
forbidden: false,
|
|
127
|
-
},
|
|
128
|
-
}, { inlineTypes: true }).code.replace(/\s/g, "")).toEqual("{ forbidden?: never; }".replace(/\s/g, ""));
|
|
129
|
-
});
|
|
130
|
-
});
|
|
131
|
-
describe("TypescriptConverter - objects (full type defs)", () => {
|
|
132
|
-
it("should convert a simple JSON schema to Typescript", () => {
|
|
133
|
-
expect(new TypescriptConverter({
|
|
134
|
-
type: "object",
|
|
135
|
-
properties: {
|
|
136
|
-
name: { type: "string" },
|
|
137
|
-
age: { type: "number" },
|
|
138
|
-
contacts: {
|
|
139
|
-
type: "array",
|
|
140
|
-
items: {
|
|
141
|
-
type: "object",
|
|
142
|
-
properties: {
|
|
143
|
-
email: { type: "string" },
|
|
144
|
-
},
|
|
145
|
-
required: ["email"],
|
|
146
|
-
},
|
|
147
|
-
},
|
|
148
|
-
profile: {
|
|
149
|
-
type: "object",
|
|
150
|
-
properties: {
|
|
151
|
-
email: { type: "string" },
|
|
152
|
-
},
|
|
153
|
-
required: ["email"],
|
|
154
|
-
},
|
|
155
|
-
},
|
|
156
|
-
required: ["name", "age"],
|
|
157
|
-
}, {}).code.replace(/\s/g, "")).toMatch(`
|
|
158
|
-
export type Contact = { email: string; };
|
|
159
|
-
|
|
160
|
-
export type Profile = { email: string; };
|
|
161
|
-
|
|
162
|
-
export type Root = { name: string; age: number; contacts?: Array<Contact>; profile?: Profile; };
|
|
163
|
-
`.replace(/\s/g, ""));
|
|
164
|
-
});
|
|
165
|
-
it("should convert a named JSON schema top-level object to Typescript", () => {
|
|
166
|
-
expect(new TypescriptConverter({
|
|
167
|
-
$schema: "http://json-schema.org/draft-07/schema#",
|
|
168
|
-
title: "Person",
|
|
169
|
-
type: "object",
|
|
170
|
-
properties: {
|
|
171
|
-
name: { type: "string" },
|
|
172
|
-
age: { type: "number" },
|
|
173
|
-
contacts: {
|
|
174
|
-
type: "array",
|
|
175
|
-
items: {
|
|
176
|
-
type: "object",
|
|
177
|
-
properties: {
|
|
178
|
-
email: { type: "string" },
|
|
179
|
-
},
|
|
180
|
-
required: ["email"],
|
|
181
|
-
},
|
|
182
|
-
},
|
|
183
|
-
profile: {
|
|
184
|
-
type: "object",
|
|
185
|
-
properties: {
|
|
186
|
-
email: { type: "string" },
|
|
187
|
-
},
|
|
188
|
-
required: ["email"],
|
|
189
|
-
},
|
|
190
|
-
},
|
|
191
|
-
required: ["name", "age"],
|
|
192
|
-
}, {}).code.replace(/\s/g, "")).toEqual(`
|
|
193
|
-
export type Contact = { email: string; };
|
|
194
|
-
|
|
195
|
-
export type Profile = { email: string; };
|
|
196
|
-
|
|
197
|
-
export type Person = { name: string; age: number; contacts?: Array<Contact>; profile?: Profile; };
|
|
198
|
-
`.replace(/\s/g, ""));
|
|
199
|
-
});
|
|
200
|
-
it("should convert JSON schema with top-level re-used objects in Typescript", async () => {
|
|
201
|
-
expect(new TypescriptConverter({
|
|
202
|
-
$schema: "http://json-schema.org/draft-07/schema#",
|
|
203
|
-
title: "Person",
|
|
204
|
-
type: "object",
|
|
205
|
-
properties: {
|
|
206
|
-
contacts: {
|
|
207
|
-
type: "array",
|
|
208
|
-
items: {
|
|
209
|
-
type: "object",
|
|
210
|
-
properties: {
|
|
211
|
-
email: { type: "string" },
|
|
212
|
-
},
|
|
213
|
-
required: ["email"],
|
|
214
|
-
},
|
|
215
|
-
},
|
|
216
|
-
profile: {
|
|
217
|
-
type: "object",
|
|
218
|
-
properties: {
|
|
219
|
-
email: { type: "string" },
|
|
220
|
-
},
|
|
221
|
-
required: ["email"],
|
|
222
|
-
},
|
|
223
|
-
contact: {
|
|
224
|
-
type: "object",
|
|
225
|
-
properties: {
|
|
226
|
-
email: { type: "string" },
|
|
227
|
-
},
|
|
228
|
-
required: ["email"],
|
|
229
|
-
},
|
|
230
|
-
email: {
|
|
231
|
-
type: "object",
|
|
232
|
-
properties: {
|
|
233
|
-
email: { type: "string" },
|
|
234
|
-
},
|
|
235
|
-
required: ["email"],
|
|
236
|
-
},
|
|
237
|
-
},
|
|
238
|
-
required: ["name", "age"],
|
|
239
|
-
}, {}).code.replace(/\s/g, "")).toEqual(`
|
|
240
|
-
export type Contact = { email: string; };
|
|
241
|
-
|
|
242
|
-
export type Profile = { email: string; };
|
|
243
|
-
|
|
244
|
-
export type Email = { email: string; };
|
|
245
|
-
|
|
246
|
-
export type Person = { contacts?: Array<Contact>; profile?: Profile; contact?: Contact; email?: Email; };
|
|
247
|
-
`.replace(/\s/g, ""));
|
|
248
|
-
});
|
|
249
|
-
it("should render never type for boolean schema false", () => {
|
|
250
|
-
expect(new TypescriptConverter({
|
|
251
|
-
type: "object",
|
|
252
|
-
properties: {
|
|
253
|
-
forbidden: false,
|
|
254
|
-
},
|
|
255
|
-
}, {}).code.replace(/\s/g, "")).toEqual("export type Root = { forbidden?: never; };".replace(/\s/g, ""));
|
|
256
|
-
});
|
|
257
|
-
});
|
|
258
|
-
//# sourceMappingURL=TypescriptConverter.objects.test.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TypescriptConverter.objects.test.js","sourceRoot":"","sources":["../src/TypescriptConverter.objects.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAC9C,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAE/D,QAAQ,CAAC,6CAA6C,EAAE,GAAG,EAAE;IAC3D,EAAE,CAAC,wBAAwB,EAAE,GAAG,EAAE;QAChC,MAAM,CACJ,IAAI,mBAAmB,CAAC;YACtB,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;gBACzB,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;aACzB;YACD,QAAQ,EAAE,CAAC,OAAO,CAAC;SACpB,CAAC,CAAC,IAAI,CACR,CAAC,OAAO,CAAC,mCAAmC,CAAC,CAAC;IACjD,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,mDAAmD,EAAE,GAAG,EAAE;QAC3D,MAAM,CACJ,IAAI,mBAAmB,CACrB;YACE,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;gBACxB,GAAG,EAAE,EAAE,IAAI,E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