@tsonic/globals 0.1.0 → 0.2.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.
Files changed (2) hide show
  1. package/index.d.ts +1 -0
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -100,6 +100,7 @@ declare global {
100
100
  type ConstructorParameters<T extends new (...args: any) => any> = T extends new (...args: infer P) => any ? P : never;
101
101
  type ReturnType<T extends (...args: any) => any> = T extends (...args: any) => infer R ? R : any;
102
102
  type InstanceType<T extends new (...args: any) => any> = T extends new (...args: any) => infer R ? R : any;
103
+ type Awaited<T> = T extends PromiseLike<infer U> ? Awaited<U> : T;
103
104
 
104
105
  /**
105
106
  * Promise types
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tsonic/globals",
3
- "version": "0.1.0",
3
+ "version": "0.2.0",
4
4
  "description": "Shared global type definitions for Tsonic (utility types, iterators, Promise, Symbol)",
5
5
  "main": "index.d.ts",
6
6
  "types": "index.d.ts",