@hey-api/openapi-ts 0.66.6 → 0.67.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/dist/chunk-KA5ZRR75.js +13 -0
- package/dist/chunk-KA5ZRR75.js.map +1 -0
- package/dist/index.cjs +59 -58
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +50 -48
- package/dist/index.js.map +1 -1
- package/dist/internal.cjs +10 -11
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.d.cts +2 -2
- package/dist/internal.d.ts +2 -2
- package/dist/internal.js +1 -1
- package/dist/{types.d-BMmln0DF.d.cts → types.d-4L5W35t-.d.cts} +20 -5
- package/dist/{types.d-BMmln0DF.d.ts → types.d-4L5W35t-.d.ts} +20 -5
- package/package.json +1 -1
- package/dist/chunk-ZM64IWUT.js +0 -14
- package/dist/chunk-ZM64IWUT.js.map +0 -1
package/dist/internal.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { JSONSchema } from '@hey-api/json-schema-ref-parser';
|
|
2
|
-
import { c as Config, I as IR, W as WatchValues } from './types.d-
|
|
3
|
-
export { i as initConfigs } from './types.d-
|
|
2
|
+
import { c as Config, I as IR, W as WatchValues } from './types.d-4L5W35t-.cjs';
|
|
3
|
+
export { i as initConfigs } from './types.d-4L5W35t-.cjs';
|
|
4
4
|
import 'node:fs';
|
|
5
5
|
import 'typescript';
|
|
6
6
|
|
package/dist/internal.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { JSONSchema } from '@hey-api/json-schema-ref-parser';
|
|
2
|
-
import { c as Config, I as IR, W as WatchValues } from './types.d-
|
|
3
|
-
export { i as initConfigs } from './types.d-
|
|
2
|
+
import { c as Config, I as IR, W as WatchValues } from './types.d-4L5W35t-.js';
|
|
3
|
+
export { i as initConfigs } from './types.d-4L5W35t-.js';
|
|
4
4
|
import 'node:fs';
|
|
5
5
|
import 'typescript';
|
|
6
6
|
|
package/dist/internal.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {createRequire}from'module';export{o as getSpec,x as initConfigs,r as parseOpenApiSpec}from'./chunk-
|
|
1
|
+
import {createRequire}from'module';export{o as getSpec,x as initConfigs,r as parseOpenApiSpec}from'./chunk-KA5ZRR75.js';createRequire(import.meta.url);//# sourceMappingURL=internal.js.map
|
|
2
2
|
//# sourceMappingURL=internal.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import fs from 'node:fs';
|
|
2
|
-
import ts from 'typescript';
|
|
2
|
+
import ts, { ParsedCommandLine } from 'typescript';
|
|
3
3
|
|
|
4
4
|
interface EnumExtensions {
|
|
5
5
|
/**
|
|
@@ -7395,6 +7395,13 @@ interface UserConfig {
|
|
|
7395
7395
|
* The relative location of the output folder
|
|
7396
7396
|
*/
|
|
7397
7397
|
path: string;
|
|
7398
|
+
/**
|
|
7399
|
+
* Relative or absolute path to the tsconfig file we should use to
|
|
7400
|
+
* generate the output. If a path to tsconfig file is not provided, we
|
|
7401
|
+
* attempt to find one starting from the location of the
|
|
7402
|
+
* `@hey-api/openapi-ts` configuration file and traversing up.
|
|
7403
|
+
*/
|
|
7404
|
+
tsConfigPath?: 'off' | (string & {});
|
|
7398
7405
|
};
|
|
7399
7406
|
/**
|
|
7400
7407
|
* Plugins generate artifacts from `input`. By default, we generate SDK
|
|
@@ -7554,6 +7561,7 @@ declare class TypeScriptFile {
|
|
|
7554
7561
|
*/
|
|
7555
7562
|
private _exportFromIndex;
|
|
7556
7563
|
private _headers;
|
|
7564
|
+
private _id;
|
|
7557
7565
|
private _identifierCase;
|
|
7558
7566
|
private _imports;
|
|
7559
7567
|
private _items;
|
|
@@ -7563,13 +7571,19 @@ declare class TypeScriptFile {
|
|
|
7563
7571
|
/**
|
|
7564
7572
|
* Path relative to the client output root.
|
|
7565
7573
|
*/
|
|
7566
|
-
constructor({ dir, exportFromIndex, header, identifierCase, name, }: {
|
|
7574
|
+
constructor({ dir, exportFromIndex, header, id, identifierCase, name, }: {
|
|
7567
7575
|
dir: string;
|
|
7568
7576
|
/**
|
|
7569
7577
|
* Should the exports from this file be re-exported in the index barrel file?
|
|
7570
7578
|
*/
|
|
7571
7579
|
exportFromIndex?: boolean;
|
|
7572
7580
|
header?: boolean;
|
|
7581
|
+
/**
|
|
7582
|
+
* Unique file ID. Used to generate correct relative paths to the file.
|
|
7583
|
+
* This should be refactored later as it's basically the file name unless
|
|
7584
|
+
* nested inside another folder.
|
|
7585
|
+
*/
|
|
7586
|
+
id: string;
|
|
7573
7587
|
identifierCase?: StringCase;
|
|
7574
7588
|
name: string;
|
|
7575
7589
|
});
|
|
@@ -7583,6 +7597,7 @@ declare class TypeScriptFile {
|
|
|
7583
7597
|
namespace: keyof Namespaces;
|
|
7584
7598
|
}): Identifier;
|
|
7585
7599
|
get exportFromIndex(): boolean;
|
|
7600
|
+
get id(): string;
|
|
7586
7601
|
identifier({ namespace, ...args }: Omit<EnsureUniqueIdentifierData, 'case' | 'namespace'> & {
|
|
7587
7602
|
namespace: keyof Namespaces;
|
|
7588
7603
|
}): Identifier;
|
|
@@ -7606,8 +7621,8 @@ declare class TypeScriptFile {
|
|
|
7606
7621
|
*/
|
|
7607
7622
|
removeNode(): void;
|
|
7608
7623
|
private _setName;
|
|
7609
|
-
|
|
7610
|
-
write(separator?: string): void;
|
|
7624
|
+
private _toString;
|
|
7625
|
+
write(separator?: string, tsConfig?: ParsedCommandLine | null): void;
|
|
7611
7626
|
}
|
|
7612
7627
|
interface EnsureUniqueIdentifierData {
|
|
7613
7628
|
$ref: string;
|
|
@@ -7870,7 +7885,7 @@ interface IRSchemaObject
|
|
|
7870
7885
|
* contains any read-only or write-only fields. This value controls whether
|
|
7871
7886
|
* we split the schema into individual schemas for payloads and responses.
|
|
7872
7887
|
*/
|
|
7873
|
-
accessScopes?: ReadonlyArray<'read' | 'write'>;
|
|
7888
|
+
accessScopes?: ReadonlyArray<'both' | 'read' | 'write'>;
|
|
7874
7889
|
/**
|
|
7875
7890
|
* If type is `object`, `additionalProperties` can be used to either define
|
|
7876
7891
|
* a schema for properties not included in `properties` or disallow such
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import fs from 'node:fs';
|
|
2
|
-
import ts from 'typescript';
|
|
2
|
+
import ts, { ParsedCommandLine } from 'typescript';
|
|
3
3
|
|
|
4
4
|
interface EnumExtensions {
|
|
5
5
|
/**
|
|
@@ -7395,6 +7395,13 @@ interface UserConfig {
|
|
|
7395
7395
|
* The relative location of the output folder
|
|
7396
7396
|
*/
|
|
7397
7397
|
path: string;
|
|
7398
|
+
/**
|
|
7399
|
+
* Relative or absolute path to the tsconfig file we should use to
|
|
7400
|
+
* generate the output. If a path to tsconfig file is not provided, we
|
|
7401
|
+
* attempt to find one starting from the location of the
|
|
7402
|
+
* `@hey-api/openapi-ts` configuration file and traversing up.
|
|
7403
|
+
*/
|
|
7404
|
+
tsConfigPath?: 'off' | (string & {});
|
|
7398
7405
|
};
|
|
7399
7406
|
/**
|
|
7400
7407
|
* Plugins generate artifacts from `input`. By default, we generate SDK
|
|
@@ -7554,6 +7561,7 @@ declare class TypeScriptFile {
|
|
|
7554
7561
|
*/
|
|
7555
7562
|
private _exportFromIndex;
|
|
7556
7563
|
private _headers;
|
|
7564
|
+
private _id;
|
|
7557
7565
|
private _identifierCase;
|
|
7558
7566
|
private _imports;
|
|
7559
7567
|
private _items;
|
|
@@ -7563,13 +7571,19 @@ declare class TypeScriptFile {
|
|
|
7563
7571
|
/**
|
|
7564
7572
|
* Path relative to the client output root.
|
|
7565
7573
|
*/
|
|
7566
|
-
constructor({ dir, exportFromIndex, header, identifierCase, name, }: {
|
|
7574
|
+
constructor({ dir, exportFromIndex, header, id, identifierCase, name, }: {
|
|
7567
7575
|
dir: string;
|
|
7568
7576
|
/**
|
|
7569
7577
|
* Should the exports from this file be re-exported in the index barrel file?
|
|
7570
7578
|
*/
|
|
7571
7579
|
exportFromIndex?: boolean;
|
|
7572
7580
|
header?: boolean;
|
|
7581
|
+
/**
|
|
7582
|
+
* Unique file ID. Used to generate correct relative paths to the file.
|
|
7583
|
+
* This should be refactored later as it's basically the file name unless
|
|
7584
|
+
* nested inside another folder.
|
|
7585
|
+
*/
|
|
7586
|
+
id: string;
|
|
7573
7587
|
identifierCase?: StringCase;
|
|
7574
7588
|
name: string;
|
|
7575
7589
|
});
|
|
@@ -7583,6 +7597,7 @@ declare class TypeScriptFile {
|
|
|
7583
7597
|
namespace: keyof Namespaces;
|
|
7584
7598
|
}): Identifier;
|
|
7585
7599
|
get exportFromIndex(): boolean;
|
|
7600
|
+
get id(): string;
|
|
7586
7601
|
identifier({ namespace, ...args }: Omit<EnsureUniqueIdentifierData, 'case' | 'namespace'> & {
|
|
7587
7602
|
namespace: keyof Namespaces;
|
|
7588
7603
|
}): Identifier;
|
|
@@ -7606,8 +7621,8 @@ declare class TypeScriptFile {
|
|
|
7606
7621
|
*/
|
|
7607
7622
|
removeNode(): void;
|
|
7608
7623
|
private _setName;
|
|
7609
|
-
|
|
7610
|
-
write(separator?: string): void;
|
|
7624
|
+
private _toString;
|
|
7625
|
+
write(separator?: string, tsConfig?: ParsedCommandLine | null): void;
|
|
7611
7626
|
}
|
|
7612
7627
|
interface EnsureUniqueIdentifierData {
|
|
7613
7628
|
$ref: string;
|
|
@@ -7870,7 +7885,7 @@ interface IRSchemaObject
|
|
|
7870
7885
|
* contains any read-only or write-only fields. This value controls whether
|
|
7871
7886
|
* we split the schema into individual schemas for payloads and responses.
|
|
7872
7887
|
*/
|
|
7873
|
-
accessScopes?: ReadonlyArray<'read' | 'write'>;
|
|
7888
|
+
accessScopes?: ReadonlyArray<'both' | 'read' | 'write'>;
|
|
7874
7889
|
/**
|
|
7875
7890
|
* If type is `object`, `additionalProperties` can be used to either define
|
|
7876
7891
|
* a schema for properties not included in `properties` or disallow such
|