@@ -39,7 +39,7 @@ const args = parseArgs(Deno.args, {
39
39
40
40
console . error (
41
41
`Unknown option: ${ arg } \n` +
42
- `Run typefetch --help to see a list of available options` ,
42
+ `Run typefetch --help to see a list of available options` ,
43
43
) ;
44
44
Deno . exit ( 1 ) ;
45
45
} ,
@@ -72,7 +72,7 @@ if (args.version) {
72
72
if ( args . _ . length !== 1 || empty ( args . _ [ 0 ] ) ) {
73
73
console . error (
74
74
`Expected a single OpenAPI schema to transform\n` +
75
- `Run typefetch --help for more information` ,
75
+ `Run typefetch --help for more information` ,
76
76
) ;
77
77
Deno . exit ( 1 ) ;
78
78
}
@@ -115,23 +115,26 @@ const source = project.createSourceFile(output, undefined, {
115
115
116
116
source . addImportDeclaration ( {
117
117
isTypeOnly : true ,
118
- moduleSpecifier : `${ args [ "import" ] } /types/json${ URL . canParse ( args [ "import" ] ) ? ".ts" : ""
119
- } `,
118
+ moduleSpecifier : `${ args [ "import" ] } /types/json${
119
+ URL . canParse ( args [ "import" ] ) ? ".ts" : ""
120
+ } `,
120
121
namedImports : [ "JSONString" ] ,
121
122
} ) ;
122
123
123
124
source . addImportDeclaration ( {
124
125
isTypeOnly : true ,
125
- moduleSpecifier : `${ args [ "import" ] } /types/headers${ URL . canParse ( args [ "import" ] ) ? ".ts" : ""
126
- } `,
126
+ moduleSpecifier : `${ args [ "import" ] } /types/headers${
127
+ URL . canParse ( args [ "import" ] ) ? ".ts" : ""
128
+ } `,
127
129
namedImports : [ "TypedHeadersInit" ] ,
128
130
} ) ;
129
131
130
132
if ( options . experimentalURLSearchParams ) {
131
133
source . addImportDeclaration ( {
132
134
isTypeOnly : true ,
133
- moduleSpecifier : `${ args [ "import" ] } /types/urlsearchparams${ URL . canParse ( args [ "import" ] ) ? ".ts" : ""
134
- } `,
135
+ moduleSpecifier : `${ args [ "import" ] } /types/urlsearchparams${
136
+ URL . canParse ( args [ "import" ] ) ? ".ts" : ""
137
+ } `,
135
138
namedImports : [ "URLSearchParamsString" ] ,
136
139
} ) ;
137
140
}
0 commit comments