File tree 3 files changed +57
-0
lines changed
3 files changed +57
-0
lines changed Original file line number Diff line number Diff line change @@ -448260,6 +448260,26 @@ Generated by [AVA](https://avajs.dev).
448260
448260
}␊
448261
448261
`
448262
448262
448263
+ ## ref.7.js
448264
+
448265
+ > Expected output to match snapshot for e2e test: ref.7.js
448266
+
448267
+ `/* eslint-disable */␊
448268
+ /**␊
448269
+ * This file was automatically generated by json-schema-to-typescript.␊
448270
+ * DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,␊
448271
+ * and run json-schema-to-typescript to regenerate this file.␊
448272
+ */␊
448273
+ ␊
448274
+ export interface Sample {␊
448275
+ neighborhood?: Person[];␊
448276
+ }␊
448277
+ export interface Person {␊
448278
+ age?: number;␊
448279
+ [k: string]: unknown;␊
448280
+ }␊
448281
+ `
448282
+
448263
448283
## refWithCycle.1.js
448264
448284
448265
448285
> Expected output to match snapshot for e2e test: refWithCycle.1.js
Original file line number Diff line number Diff line change
1
+ // @see https://github.com/bcherny/json-schema-to-typescript/issues/613
2
+ export const input = {
3
+ $schema : 'https://json-schema.org/draft/2020-12/schema' ,
4
+ title : 'Sample' ,
5
+ type : 'object' ,
6
+ additionalProperties : false ,
7
+ properties : {
8
+ neighborhood : {
9
+ type : 'array' ,
10
+ items : {
11
+ $ref : '#/$defs/person' ,
12
+ } ,
13
+ } ,
14
+ } ,
15
+ $defs : {
16
+ baseType : {
17
+ title : 'BaseType' ,
18
+ type : 'object' ,
19
+ properties : {
20
+ name : {
21
+ type : 'string' ,
22
+ } ,
23
+ } ,
24
+ } ,
25
+ person : {
26
+ title : 'Person' ,
27
+ $ref : '#/$defs/baseType' ,
28
+ type : 'object' ,
29
+ unevaluatedProperties : false ,
30
+ properties : {
31
+ age : {
32
+ type : 'number' ,
33
+ } ,
34
+ } ,
35
+ } ,
36
+ } ,
37
+ }
You can’t perform that action at this time.
0 commit comments