@tsonic/globals 0.3.5 → 0.3.7

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.
Files changed (2) hide show
  1. package/index.d.ts +11 -0
  2. package/package.json +2 -2
package/index.d.ts CHANGED
@@ -42,6 +42,17 @@ declare global {
42
42
  [Symbol.iterator](): IterableIterator<T>;
43
43
  }
44
44
 
45
+ /**
46
+ * ArrayConstructor - allows new Array<T>(size) syntax
47
+ * In dotnet mode: emits as new T[size]
48
+ * In js mode: emits as new List<T>() with capacity
49
+ */
50
+ interface ArrayConstructor {
51
+ new <T>(size?: number): T[];
52
+ }
53
+
54
+ const Array: ArrayConstructor;
55
+
45
56
  /**
46
57
  * String - augmented with BCL methods from System.String
47
58
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tsonic/globals",
3
- "version": "0.3.5",
3
+ "version": "0.3.7",
4
4
  "description": "Global type definitions for Tsonic with BCL primitive methods",
5
5
  "main": "index.d.ts",
6
6
  "types": "index.d.ts",
@@ -8,7 +8,7 @@
8
8
  "typecheck": "tsc --noEmit"
9
9
  },
10
10
  "dependencies": {
11
- "@tsonic/dotnet": "^0.8.1"
11
+ "@tsonic/dotnet": "0.8.7"
12
12
  },
13
13
  "devDependencies": {
14
14
  "typescript": "^5.0.0"