@ts-for-gir/generator-typescript 4.0.0-beta.33 → 4.0.0-beta.34

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ts-for-gir/generator-typescript",
3
- "version": "4.0.0-beta.33",
3
+ "version": "4.0.0-beta.34",
4
4
  "description": "TypeScript type definition generator for ts-for-gir",
5
5
  "main": "src/index.ts",
6
6
  "module": "src/index.ts",
@@ -37,10 +37,10 @@
37
37
  "typescript": "^5.9.2"
38
38
  },
39
39
  "dependencies": {
40
- "@gi.ts/parser": "^4.0.0-beta.33",
41
- "@ts-for-gir/generator-base": "^4.0.0-beta.33",
42
- "@ts-for-gir/lib": "^4.0.0-beta.33",
43
- "@ts-for-gir/templates": "^4.0.0-beta.33",
40
+ "@gi.ts/parser": "^4.0.0-beta.34",
41
+ "@ts-for-gir/generator-base": "^4.0.0-beta.34",
42
+ "@ts-for-gir/lib": "^4.0.0-beta.34",
43
+ "@ts-for-gir/templates": "^4.0.0-beta.34",
44
44
  "ejs": "^3.1.10",
45
45
  "xml2js": "^0.6.2"
46
46
  }
@@ -1485,9 +1485,11 @@ export class ModuleGenerator extends FormatGenerator<string[]> {
1485
1485
  return ` extends ${Type}`;
1486
1486
  }
1487
1487
 
1488
- throw new Error(
1488
+ // Fallback to GObject.Object when supertype can't be resolved
1489
+ this.log.warn(
1489
1490
  `Unable to resolve type: ${node.superType.name} from ${node.superType.namespace} in ${node.namespace.namespace} ${node.namespace.version}, falling back to GObject.Object`,
1490
1491
  );
1492
+ return ` extends GObject.Object`;
1491
1493
  }
1492
1494
 
1493
1495
  return "";