@openapi-qraft/openapi-typescript-plugin 1.2.0-next.14 → 1.2.0-next.16

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/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # @openapi-qraft/openapi-typescript
2
2
 
3
+ ## 1.2.0-next.16
4
+
5
+ ### Patch Changes
6
+
7
+ - @openapi-qraft/plugin@2.0.0-next.16
8
+
9
+ ## 1.2.0-next.15
10
+
11
+ ### Patch Changes
12
+
13
+ - 4b1c13f: Fixed support for the `--explicit-import-extensions .ts` option when using the `openapi-typescript-plugin`.
14
+ - @openapi-qraft/plugin@2.0.0-next.15
15
+
3
16
  ## 1.2.0-next.14
4
17
 
5
18
  ### Patch Changes
@@ -3,7 +3,7 @@
3
3
  * @param openapiTypesFileName The file name of the OpenAPI types file. Eg: `schema.d.ts`
4
4
  * @param explicitImportExtensions Whether to include explicit `.js` extensions in the import path.
5
5
  */
6
- export declare function createOpenapiTypesImportPath(openapiTypesFileName: string, explicitImportExtensions: boolean): string;
6
+ export declare function createOpenapiTypesImportPath(openapiTypesFileName: string, explicitImportExtensions: '.ts' | '.js' | undefined): string;
7
7
  /**
8
8
  * Check if the file name is a valid TypeScript file name.
9
9
  * Eg: `schema.d.ts`, `schema.ts`
@@ -1 +1 @@
1
- {"version":3,"file":"createOpenapiTypesImportPath.d.ts","sourceRoot":"","sources":["../../src/lib/createOpenapiTypesImportPath.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wBAAgB,4BAA4B,CAC1C,oBAAoB,EAAE,MAAM,EAC5B,wBAAwB,EAAE,OAAO,UAQlC;AAUD;;;GAGG;AACH,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,MAAM,WAEzD"}
1
+ {"version":3,"file":"createOpenapiTypesImportPath.d.ts","sourceRoot":"","sources":["../../src/lib/createOpenapiTypesImportPath.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wBAAgB,4BAA4B,CAC1C,oBAAoB,EAAE,MAAM,EAC5B,wBAAwB,EAAE,KAAK,GAAG,KAAK,GAAG,SAAS,UAQpD;AAUD;;;GAGG;AACH,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,MAAM,WAEzD"}
@@ -7,7 +7,7 @@ export function createOpenapiTypesImportPath(openapiTypesFileName, explicitImpor
7
7
  if (openapiTypesFileName.endsWith('.d.ts'))
8
8
  return `../${getTypeScriptFileBaseName(openapiTypesFileName)}.d.ts`;
9
9
  return explicitImportExtensions
10
- ? `../${getTypeScriptFileBaseName(openapiTypesFileName)}.js`
10
+ ? `../${getTypeScriptFileBaseName(openapiTypesFileName)}${explicitImportExtensions}`
11
11
  : `../${openapiTypesFileName}`;
12
12
  }
13
13
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"createOpenapiTypesImportPath.js","sourceRoot":"","sources":["../../src/lib/createOpenapiTypesImportPath.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,UAAU,4BAA4B,CAC1C,oBAA4B,EAC5B,wBAAiC;IAEjC,IAAI,oBAAoB,CAAC,QAAQ,CAAC,OAAO,CAAC;QACxC,OAAO,MAAM,yBAAyB,CAAC,oBAAoB,CAAC,OAAO,CAAC;IAEtE,OAAO,wBAAwB;QAC7B,CAAC,CAAC,MAAM,yBAAyB,CAAC,oBAAoB,CAAC,KAAK;QAC5D,CAAC,CAAC,MAAM,oBAAoB,EAAE,CAAC;AACnC,CAAC;AAED;;;GAGG;AACH,SAAS,yBAAyB,CAAC,oBAA4B;IAC7D,OAAO,oBAAoB,CAAC,OAAO,CAAC,oBAAoB,EAAE,EAAE,EAAE,CAAC,CAAC;AAClE,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,yBAAyB,CAAC,QAAgB;IACxD,OAAO,oBAAoB,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;AAC/C,CAAC;AAED,SAAS,oBAAoB;IAC3B,OAAO,aAAa,CAAC;AACvB,CAAC"}
1
+ {"version":3,"file":"createOpenapiTypesImportPath.js","sourceRoot":"","sources":["../../src/lib/createOpenapiTypesImportPath.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,UAAU,4BAA4B,CAC1C,oBAA4B,EAC5B,wBAAmD;IAEnD,IAAI,oBAAoB,CAAC,QAAQ,CAAC,OAAO,CAAC;QACxC,OAAO,MAAM,yBAAyB,CAAC,oBAAoB,CAAC,OAAO,CAAC;IAEtE,OAAO,wBAAwB;QAC7B,CAAC,CAAC,MAAM,yBAAyB,CAAC,oBAAoB,CAAC,GAAG,wBAAwB,EAAE;QACpF,CAAC,CAAC,MAAM,oBAAoB,EAAE,CAAC;AACnC,CAAC;AAED;;;GAGG;AACH,SAAS,yBAAyB,CAAC,oBAA4B;IAC7D,OAAO,oBAAoB,CAAC,OAAO,CAAC,oBAAoB,EAAE,EAAE,EAAE,CAAC,CAAC;AAClE,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,yBAAyB,CAAC,QAAgB;IACxD,OAAO,oBAAoB,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;AAC/C,CAAC;AAED,SAAS,oBAAoB;IAC3B,OAAO,aAAa,CAAC;AACvB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openapi-qraft/openapi-typescript-plugin",
3
- "version": "1.2.0-next.14",
3
+ "version": "1.2.0-next.16",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "build": "tsc --project tsconfig.build.json",
@@ -26,7 +26,7 @@
26
26
  }
27
27
  },
28
28
  "dependencies": {
29
- "@openapi-qraft/plugin": "^2.0.0-next.14",
29
+ "@openapi-qraft/plugin": "^2.0.0-next.16",
30
30
  "openapi-typescript": "^7.4.0",
31
31
  "typescript": "^5.6.2"
32
32
  },
@@ -5,13 +5,13 @@
5
5
  */
6
6
  export function createOpenapiTypesImportPath(
7
7
  openapiTypesFileName: string,
8
- explicitImportExtensions: boolean
8
+ explicitImportExtensions: '.ts' | '.js' | undefined
9
9
  ) {
10
10
  if (openapiTypesFileName.endsWith('.d.ts'))
11
11
  return `../${getTypeScriptFileBaseName(openapiTypesFileName)}.d.ts`;
12
12
 
13
13
  return explicitImportExtensions
14
- ? `../${getTypeScriptFileBaseName(openapiTypesFileName)}.js`
14
+ ? `../${getTypeScriptFileBaseName(openapiTypesFileName)}${explicitImportExtensions}`
15
15
  : `../${openapiTypesFileName}`;
16
16
  }
17
17