@@ -3706,19 +3706,22 @@ export type { CompositionWithAllOfAndNullable } from './models/CompositionWithAl
3706
3706
export type { CompositionWithAnyOf } from './models/CompositionWithAnyOf';
3707
3707
export type { CompositionWithAnyOfAndNullable } from './models/CompositionWithAnyOfAndNullable';
3708
3708
export type { CompositionWithAnyOfAnonymous } from './models/CompositionWithAnyOfAnonymous';
3709
+ export type { CompositionWithNestedAnyOfAndNull } from './models/CompositionWithNestedAnyOfAndNull';
3709
3710
export type { CompositionWithOneOf } from './models/CompositionWithOneOf';
3710
3711
export type { CompositionWithOneOfAndComplexArrayDictionary } from './models/CompositionWithOneOfAndComplexArrayDictionary';
3711
3712
export type { CompositionWithOneOfAndNullable } from './models/CompositionWithOneOfAndNullable';
3712
3713
export type { CompositionWithOneOfAndSimpleArrayDictionary } from './models/CompositionWithOneOfAndSimpleArrayDictionary';
3713
3714
export type { CompositionWithOneOfAndSimpleDictionary } from './models/CompositionWithOneOfAndSimpleDictionary';
3714
3715
export type { CompositionWithOneOfAnonymous } from './models/CompositionWithOneOfAnonymous';
3715
3716
export type { CompositionWithOneOfDiscriminator } from './models/CompositionWithOneOfDiscriminator';
3717
+ export type { ConstValue } from './models/ConstValue';
3716
3718
export type { DeprecatedModel } from './models/DeprecatedModel';
3717
3719
export type { DictionaryWithArray } from './models/DictionaryWithArray';
3718
3720
export type { DictionaryWithDictionary } from './models/DictionaryWithDictionary';
3719
3721
export type { DictionaryWithProperties } from './models/DictionaryWithProperties';
3720
3722
export type { DictionaryWithReference } from './models/DictionaryWithReference';
3721
3723
export type { DictionaryWithString } from './models/DictionaryWithString';
3724
+ export { Enum1 } from './models/Enum1';
3722
3725
export type { EnumFromDescription } from './models/EnumFromDescription';
3723
3726
export { EnumWithExtensions } from './models/EnumWithExtensions';
3724
3727
export { EnumWithNumbers } from './models/EnumWithNumbers';
@@ -3734,6 +3737,7 @@ export type { ModelThatExtendsExtends } from './models/ModelThatExtendsExtends';
3734
3737
export type { ModelWithArray } from './models/ModelWithArray';
3735
3738
export type { ModelWithBoolean } from './models/ModelWithBoolean';
3736
3739
export type { ModelWithCircularReference } from './models/ModelWithCircularReference';
3740
+ export type { ModelWithConst } from './models/ModelWithConst';
3737
3741
export type { ModelWithDictionary } from './models/ModelWithDictionary';
3738
3742
export type { ModelWithDuplicateImports } from './models/ModelWithDuplicateImports';
3739
3743
export type { ModelWithDuplicateProperties } from './models/ModelWithDuplicateProperties';
@@ -3776,19 +3780,22 @@ export { $CompositionWithAllOfAndNullable } from './schemas/$CompositionWithAllO
3776
3780
export { $CompositionWithAnyOf } from './schemas/$CompositionWithAnyOf';
3777
3781
export { $CompositionWithAnyOfAndNullable } from './schemas/$CompositionWithAnyOfAndNullable';
3778
3782
export { $CompositionWithAnyOfAnonymous } from './schemas/$CompositionWithAnyOfAnonymous';
3783
+ export { $CompositionWithNestedAnyOfAndNull } from './schemas/$CompositionWithNestedAnyOfAndNull';
3779
3784
export { $CompositionWithOneOf } from './schemas/$CompositionWithOneOf';
3780
3785
export { $CompositionWithOneOfAndComplexArrayDictionary } from './schemas/$CompositionWithOneOfAndComplexArrayDictionary';
3781
3786
export { $CompositionWithOneOfAndNullable } from './schemas/$CompositionWithOneOfAndNullable';
3782
3787
export { $CompositionWithOneOfAndSimpleArrayDictionary } from './schemas/$CompositionWithOneOfAndSimpleArrayDictionary';
3783
3788
export { $CompositionWithOneOfAndSimpleDictionary } from './schemas/$CompositionWithOneOfAndSimpleDictionary';
3784
3789
export { $CompositionWithOneOfAnonymous } from './schemas/$CompositionWithOneOfAnonymous';
3785
3790
export { $CompositionWithOneOfDiscriminator } from './schemas/$CompositionWithOneOfDiscriminator';
3791
+ export { $ConstValue } from './schemas/$ConstValue';
3786
3792
export { $DeprecatedModel } from './schemas/$DeprecatedModel';
3787
3793
export { $DictionaryWithArray } from './schemas/$DictionaryWithArray';
3788
3794
export { $DictionaryWithDictionary } from './schemas/$DictionaryWithDictionary';
3789
3795
export { $DictionaryWithProperties } from './schemas/$DictionaryWithProperties';
3790
3796
export { $DictionaryWithReference } from './schemas/$DictionaryWithReference';
3791
3797
export { $DictionaryWithString } from './schemas/$DictionaryWithString';
3798
+ export { $Enum1 } from './schemas/$Enum1';
3792
3799
export { $EnumFromDescription } from './schemas/$EnumFromDescription';
3793
3800
export { $EnumWithExtensions } from './schemas/$EnumWithExtensions';
3794
3801
export { $EnumWithNumbers } from './schemas/$EnumWithNumbers';
@@ -3804,6 +3811,7 @@ export { $ModelThatExtendsExtends } from './schemas/$ModelThatExtendsExtends';
3804
3811
export { $ModelWithArray } from './schemas/$ModelWithArray';
3805
3812
export { $ModelWithBoolean } from './schemas/$ModelWithBoolean';
3806
3813
export { $ModelWithCircularReference } from './schemas/$ModelWithCircularReference';
3814
+ export { $ModelWithConst } from './schemas/$ModelWithConst';
3807
3815
export { $ModelWithDictionary } from './schemas/$ModelWithDictionary';
3808
3816
export { $ModelWithDuplicateImports } from './schemas/$ModelWithDuplicateImports';
3809
3817
export { $ModelWithDuplicateProperties } from './schemas/$ModelWithDuplicateProperties';
@@ -4125,6 +4133,23 @@ export type CompositionWithAnyOfAnonymous = {
4125
4133
"
4126
4134
`;
4127
4135
4136
+ exports[`v3 should generate: test/generated/v3/models/CompositionWithNestedAnyOfAndNull.ts 1`] = `
4137
+ "/* generated using openapi-typescript-codegen -- do no edit */
4138
+ /* istanbul ignore file */
4139
+ /* tslint:disable */
4140
+ /* eslint-disable */
4141
+ import type { ConstValue } from './ConstValue';
4142
+ import type { Enum1 } from './Enum1';
4143
+ /**
4144
+ * This is a model with one property with a 'any of' relationship where the options are not $ref
4145
+ */
4146
+ export type CompositionWithNestedAnyOfAndNull = {
4147
+ propA?: ((Enum1 | ConstValue) | null);
4148
+ };
4149
+
4150
+ "
4151
+ `;
4152
+
4128
4153
exports[`v3 should generate: test/generated/v3/models/CompositionWithOneOf.ts 1`] = `
4129
4154
"/* generated using openapi-typescript-codegen -- do no edit */
4130
4155
/* istanbul ignore file */
@@ -4241,6 +4266,15 @@ export type CompositionWithOneOfDiscriminator = (ModelCircle | ModelSquare);
4241
4266
"
4242
4267
`;
4243
4268
4269
+ exports[`v3 should generate: test/generated/v3/models/ConstValue.ts 1`] = `
4270
+ "/* generated using openapi-typescript-codegen -- do no edit */
4271
+ /* istanbul ignore file */
4272
+ /* tslint:disable */
4273
+ /* eslint-disable */
4274
+ export type ConstValue = "ConstValue";
4275
+ "
4276
+ `;
4277
+
4244
4278
exports[`v3 should generate: test/generated/v3/models/DeprecatedModel.ts 1`] = `
4245
4279
"/* generated using openapi-typescript-codegen -- do no edit */
4246
4280
/* istanbul ignore file */
@@ -4326,6 +4360,18 @@ export type DictionaryWithString = Record<string, string>;
4326
4360
"
4327
4361
`;
4328
4362
4363
+ exports[`v3 should generate: test/generated/v3/models/Enum1.ts 1`] = `
4364
+ "/* generated using openapi-typescript-codegen -- do no edit */
4365
+ /* istanbul ignore file */
4366
+ /* tslint:disable */
4367
+ /* eslint-disable */
4368
+ export enum Enum1 {
4369
+ BIRD = 'Bird',
4370
+ DOG = 'Dog',
4371
+ }
4372
+ "
4373
+ `;
4374
+
4329
4375
exports[`v3 should generate: test/generated/v3/models/EnumFromDescription.ts 1`] = `
4330
4376
"/* generated using openapi-typescript-codegen -- do no edit */
4331
4377
/* istanbul ignore file */
@@ -4579,6 +4625,21 @@ export type ModelWithCircularReference = {
4579
4625
"
4580
4626
`;
4581
4627
4628
+ exports[`v3 should generate: test/generated/v3/models/ModelWithConst.ts 1`] = `
4629
+ "/* generated using openapi-typescript-codegen -- do no edit */
4630
+ /* istanbul ignore file */
4631
+ /* tslint:disable */
4632
+ /* eslint-disable */
4633
+ export type ModelWithConst = {
4634
+ String?: "String";
4635
+ number?: 0;
4636
+ null?: null;
4637
+ withType?: "Some string";
4638
+ };
4639
+
4640
+ "
4641
+ `;
4642
+
4582
4643
exports[`v3 should generate: test/generated/v3/models/ModelWithDictionary.ts 1`] = `
4583
4644
"/* generated using openapi-typescript-codegen -- do no edit */
4584
4645
/* istanbul ignore file */
@@ -5323,6 +5384,32 @@ export const $CompositionWithAnyOfAnonymous = {
5323
5384
"
5324
5385
`;
5325
5386
5387
+ exports[`v3 should generate: test/generated/v3/schemas/$CompositionWithNestedAnyOfAndNull.ts 1`] = `
5388
+ "/* generated using openapi-typescript-codegen -- do no edit */
5389
+ /* istanbul ignore file */
5390
+ /* tslint:disable */
5391
+ /* eslint-disable */
5392
+ export const $CompositionWithNestedAnyOfAndNull = {
5393
+ description: \`This is a model with one property with a 'any of' relationship where the options are not $ref\`,
5394
+ properties: {
5395
+ propA: {
5396
+ type: 'any-of',
5397
+ contains: [{
5398
+ type: 'any-of',
5399
+ contains: [{
5400
+ type: 'Enum1',
5401
+ }, {
5402
+ type: 'ConstValue',
5403
+ }],
5404
+ }, {
5405
+ type: 'null',
5406
+ }],
5407
+ },
5408
+ },
5409
+ } as const;
5410
+ "
5411
+ `;
5412
+
5326
5413
exports[`v3 should generate: test/generated/v3/schemas/$CompositionWithOneOf.ts 1`] = `
5327
5414
"/* generated using openapi-typescript-codegen -- do no edit */
5328
5415
/* istanbul ignore file */
@@ -5508,6 +5595,17 @@ export const $CompositionWithOneOfDiscriminator = {
5508
5595
"
5509
5596
`;
5510
5597
5598
+ exports[`v3 should generate: test/generated/v3/schemas/$ConstValue.ts 1`] = `
5599
+ "/* generated using openapi-typescript-codegen -- do no edit */
5600
+ /* istanbul ignore file */
5601
+ /* tslint:disable */
5602
+ /* eslint-disable */
5603
+ export const $ConstValue = {
5604
+ type: '"ConstValue"',
5605
+ } as const;
5606
+ "
5607
+ `;
5608
+
5511
5609
exports[`v3 should generate: test/generated/v3/schemas/$DeprecatedModel.ts 1`] = `
5512
5610
"/* generated using openapi-typescript-codegen -- do no edit */
5513
5611
/* istanbul ignore file */
@@ -5608,6 +5706,17 @@ export const $DictionaryWithString = {
5608
5706
"
5609
5707
`;
5610
5708
5709
+ exports[`v3 should generate: test/generated/v3/schemas/$Enum1.ts 1`] = `
5710
+ "/* generated using openapi-typescript-codegen -- do no edit */
5711
+ /* istanbul ignore file */
5712
+ /* tslint:disable */
5713
+ /* eslint-disable */
5714
+ export const $Enum1 = {
5715
+ type: 'Enum',
5716
+ } as const;
5717
+ "
5718
+ `;
5719
+
5611
5720
exports[`v3 should generate: test/generated/v3/schemas/$EnumFromDescription.ts 1`] = `
5612
5721
"/* generated using openapi-typescript-codegen -- do no edit */
5613
5722
/* istanbul ignore file */
@@ -5890,6 +5999,30 @@ export const $ModelWithCircularReference = {
5890
5999
"
5891
6000
`;
5892
6001
6002
+ exports[`v3 should generate: test/generated/v3/schemas/$ModelWithConst.ts 1`] = `
6003
+ "/* generated using openapi-typescript-codegen -- do no edit */
6004
+ /* istanbul ignore file */
6005
+ /* tslint:disable */
6006
+ /* eslint-disable */
6007
+ export const $ModelWithConst = {
6008
+ properties: {
6009
+ String: {
6010
+ type: '"String"',
6011
+ },
6012
+ number: {
6013
+ type: '0',
6014
+ },
6015
+ null: {
6016
+ type: 'null',
6017
+ },
6018
+ withType: {
6019
+ type: '"Some string"',
6020
+ },
6021
+ },
6022
+ } as const;
6023
+ "
6024
+ `;
6025
+
5893
6026
exports[`v3 should generate: test/generated/v3/schemas/$ModelWithDictionary.ts 1`] = `
5894
6027
"/* generated using openapi-typescript-codegen -- do no edit */
5895
6028
/* istanbul ignore file */
0 commit comments