@workos/oagen 0.1.0 → 0.1.1

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.
@@ -945,6 +945,14 @@ async function mergeIntoExisting(existingContent, generatedContent, language, he
945
945
  preserved++;
946
946
  continue;
947
947
  }
948
+ const braceMatch = imp.text.match(/\{([^}]+)\}/);
949
+ if (braceMatch) {
950
+ const names = braceMatch[1].split(",").map((n) => n.replace(/\btype\b/, "").trim()).filter(Boolean);
951
+ if (names.length > 0 && names.every((n) => existingImportedNames.has(n))) {
952
+ preserved++;
953
+ continue;
954
+ }
955
+ }
948
956
  newImports.push(imp);
949
957
  }
950
958
  for (const stmt of generatedStatements.statements) {
package/dist/cli/index.js CHANGED
@@ -2542,6 +2542,14 @@ async function mergeIntoExisting(existingContent, generatedContent, language, he
2542
2542
  preserved++;
2543
2543
  continue;
2544
2544
  }
2545
+ const braceMatch = imp.text.match(/\{([^}]+)\}/);
2546
+ if (braceMatch) {
2547
+ const names = braceMatch[1].split(",").map((n) => n.replace(/\btype\b/, "").trim()).filter(Boolean);
2548
+ if (names.length > 0 && names.every((n) => existingImportedNames.has(n))) {
2549
+ preserved++;
2550
+ continue;
2551
+ }
2552
+ }
2545
2553
  newImports.push(imp);
2546
2554
  }
2547
2555
  for (const stmt of generatedStatements.statements) {
package/dist/index.js CHANGED
@@ -9,7 +9,7 @@ import {
9
9
  integrateGeneratedFiles,
10
10
  mapFilesForTargetIntegration,
11
11
  registerEmitter
12
- } from "./chunk-VUSRNIG2.js";
12
+ } from "./chunk-2JXFTDTO.js";
13
13
  import {
14
14
  ACRONYM_SET,
15
15
  CommandError,
@@ -2,7 +2,7 @@ import {
2
2
  diffSpecs,
3
3
  generate,
4
4
  getEmitter
5
- } from "../chunk-VUSRNIG2.js";
5
+ } from "../chunk-2JXFTDTO.js";
6
6
  import {
7
7
  buildOverlayLookup,
8
8
  diffSurfaces,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@workos/oagen",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Framework for building OpenAPI SDK emitters",
5
5
  "author": "WorkOS",
6
6
  "license": "MIT",
@@ -83,6 +83,7 @@
83
83
  "tree-sitter-ruby": "^0.21.0",
84
84
  "tree-sitter-rust": "^0.21.0",
85
85
  "tree-sitter-typescript": "^0.23.2",
86
+ "dotenv": "^17.3.1",
86
87
  "tsx": "^4.19.0",
87
88
  "typescript": "^5.7.0"
88
89
  },
@@ -91,7 +92,6 @@
91
92
  "@commitlint/config-conventional": "^20.5.0",
92
93
  "@types/node": "^25.3.3",
93
94
  "@vitest/coverage-v8": "^3.2.4",
94
- "dotenv": "^17.3.1",
95
95
  "husky": "^9.1.7",
96
96
  "oxfmt": "^0.36.0",
97
97
  "oxlint": "^1.51.0",