@@ -2,109 +2,106 @@ import path from 'node:path';
2
2
3
3
import { defineConfig } from '../src' ;
4
4
5
- export default defineConfig ( {
6
- // experimentalParser: false,
7
- input : {
8
- branch : 'main' ,
9
- // exclude: '^#/components/schemas/ModelWithCircularReference$',
10
- // include:
11
- // '^(#/components/schemas/import|#/paths/api/v{api-version}/simple/options)$',
12
- organization : 'hey-api' ,
13
- // path: {
14
- // components: {},
15
- // info: {
16
- // version: '1.0.0',
17
- // },
18
- // openapi: '3.1.0',
19
- // paths: {},
20
- // },
21
- // path: path.resolve(__dirname, 'spec', '3.1.x', 'full.json'),
22
- // path: 'http://localhost:4000/',
23
- path : 'https://get.heyapi.dev/' ,
24
- // path: 'https://get.heyapi.dev/hey-api/backend?branch=main&version=1.0.0',
25
- // path: 'http://localhost:8000/openapi.json',
26
- // path: './test/spec/v3-transforms.json',
27
- // path: 'https://mongodb-mms-prod-build-server.s3.amazonaws.com/openapi/2caffd88277a4e27c95dcefc7e3b6a63a3b03297-v2-2023-11-15.json',
28
- // path: 'https://raw.githubusercontent.com/swagger-api/swagger-petstore/master/src/main/resources/openapi.yaml',
29
- // project: 'backend',
30
- project : 'upload-openapi-spec' ,
31
- // version: '1.0.0',
32
- } ,
33
- logs : {
34
- // level: 'debug',
35
- path : './logs' ,
36
- } ,
37
- // name: 'foo',
38
- output : {
39
- // case: 'snake_case',
40
- // format: 'prettier',
41
- // indexFile: false,
42
- // lint: 'eslint',
43
- path : path . resolve ( __dirname , 'generated' , 'sample' ) ,
44
- } ,
45
- plugins : [
46
- // @ts -ignore
47
- {
48
- baseUrl : false ,
49
- // bundle: true,
50
- exportFromIndex : true ,
51
- name : '@hey-api/client-fetch' ,
52
- strictBaseUrl : true ,
53
- } ,
54
- // @ts -ignore
55
- {
56
- // name: '@hey-api/schemas',
57
- // type: 'json',
58
- } ,
59
- // @ts -ignore
60
- {
61
- // asClass: true,
62
- // auth: false,
63
- // client: false,
64
- // include...
65
- name : '@hey-api/sdk' ,
66
- // operationId: false,
67
- // serviceNameBuilder: '^Parameters',
68
- // throwOnError: true,
69
- // transformer: '@hey-api/transformers',
70
- // transformer: true,
71
- // validator: 'zod',
72
- } ,
73
- // @ts -ignore
74
- {
75
- bigInt : true ,
76
- dates : true ,
77
- // name: '@hey-api/transformers',
5
+ // @ts -ignore
6
+ // eslint-disable-next-line arrow-body-style
7
+ export default defineConfig ( ( ) => {
8
+ // ...
9
+ return {
10
+ // experimentalParser: false,
11
+ input : {
12
+ branch : 'main' ,
13
+ // exclude: '^#/components/schemas/ModelWithCircularReference$',
14
+ // include:
15
+ // '^(#/components/schemas/import|#/paths/api/v{api-version}/simple/options)$',
16
+ organization : 'hey-api' ,
17
+ // path: {
18
+ // components: {},
19
+ // info: {
20
+ // version: '1.0.0',
21
+ // },
22
+ // openapi: '3.1.0',
23
+ // paths: {},
24
+ // },
25
+ // path: path.resolve(__dirname, 'spec', '3.1.x', 'full.json'),
26
+ // path: 'http://localhost:4000/',
27
+ path : 'https://get.heyapi.dev/' ,
28
+ // path: 'https://get.heyapi.dev/hey-api/backend?branch=main&version=1.0.0',
29
+ // path: 'http://localhost:8000/openapi.json',
30
+ // path: './test/spec/v3-transforms.json',
31
+ // path: 'https://mongodb-mms-prod-build-server.s3.amazonaws.com/openapi/2caffd88277a4e27c95dcefc7e3b6a63a3b03297-v2-2023-11-15.json',
32
+ // path: 'https://raw.githubusercontent.com/swagger-api/swagger-petstore/master/src/main/resources/openapi.yaml',
33
+ // project: 'backend',
34
+ project : 'upload-openapi-spec' ,
35
+ // version: '1.0.0',
78
36
} ,
79
- // @ts -ignore
80
- {
81
- // enums: 'typescript',
82
- // enums: 'typescript+namespace',
83
- // enums: 'javascript',
84
- // enumsCase: 'camelCase',
85
- // exportInlineEnums: true,
86
- // identifierCase: 'preserve',
87
- name : '@hey-api/typescript' ,
88
- // tree: true,
37
+ logs : {
38
+ // level: 'debug',
39
+ path : './logs' ,
89
40
} ,
90
- // @ts -ignore
91
- {
92
- // name: 'fastify',
41
+ // name: 'foo',
42
+ output : {
43
+ // case: 'snake_case',
44
+ // format: 'prettier',
45
+ // indexFile: false,
46
+ // lint: 'eslint',
47
+ path : path . resolve ( __dirname , 'generated' , 'sample' ) ,
93
48
} ,
94
- // @ts -ignore
95
- {
96
- name : '@tanstack/react-query' ,
97
- } ,
98
- // @ts -ignore
99
- {
100
- // exportFromIndex: true,
101
- // name: 'zod',
102
- } ,
103
- ] ,
104
- // useOptions: false,
105
- // watch: {
106
- // enabled: true,
107
- // interval: 1_000,
108
- // timeout: 60_000,
109
- // },
49
+ plugins : [
50
+ {
51
+ baseUrl : false ,
52
+ // bundle: true,
53
+ exportFromIndex : true ,
54
+ name : '@hey-api/client-fetch' ,
55
+ strictBaseUrl : true ,
56
+ } ,
57
+ {
58
+ // name: '@hey-api/schemas',
59
+ // type: 'json',
60
+ } ,
61
+ {
62
+ // asClass: true,
63
+ // auth: false,
64
+ // client: false,
65
+ // include...
66
+ name : '@hey-api/sdk' ,
67
+ // operationId: false,
68
+ // serviceNameBuilder: '^Parameters',
69
+ // throwOnError: true,
70
+ // transformer: '@hey-api/transformers',
71
+ // transformer: true,
72
+ // validator: 'zod',
73
+ } ,
74
+ {
75
+ bigInt : true ,
76
+ dates : true ,
77
+ // name: '@hey-api/transformers',
78
+ } ,
79
+ {
80
+ // enums: 'typescript',
81
+ // enums: 'typescript+namespace',
82
+ // enums: 'javascript',
83
+ // enumsCase: 'camelCase',
84
+ // exportInlineEnums: true,
85
+ // identifierCase: 'preserve',
86
+ name : '@hey-api/typescript' ,
87
+ // tree: true,
88
+ } ,
89
+ {
90
+ // name: 'fastify',
91
+ } ,
92
+ {
93
+ name : '@tanstack/react-query' ,
94
+ } ,
95
+ {
96
+ // exportFromIndex: true,
97
+ // name: 'zod',
98
+ } ,
99
+ ] ,
100
+ // useOptions: false,
101
+ // watch: {
102
+ // enabled: true,
103
+ // interval: 1_000,
104
+ // timeout: 60_000,
105
+ // },
106
+ } ;
110
107
} ) ;
0 commit comments