type-tls 3.8.0 → 3.9.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.
- package/dist/class.d.ts +7 -5
- package/package.json +1 -1
package/dist/class.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* 类的类型、构造函数的类型
|
|
3
3
|
*
|
|
4
|
-
* @typeParam Arg - 构建函数的参数类型
|
|
5
4
|
* @typeParam Instance - 构建函数的返回的实例类型
|
|
5
|
+
* @typeParam Arg - 构建函数的参数类型
|
|
6
6
|
*/
|
|
7
|
-
export interface ClassType<Arg extends any[] = any
|
|
7
|
+
export interface ClassType<Instance = any, Arg extends any[] = any> {
|
|
8
8
|
/**
|
|
9
9
|
* 类的构造函数
|
|
10
10
|
*/
|
|
@@ -17,14 +17,16 @@ export interface ClassType<Arg extends any[] = any, Instance = any> {
|
|
|
17
17
|
/**
|
|
18
18
|
* 构造函数的类型
|
|
19
19
|
*
|
|
20
|
-
* @typeParam Arg - 构建函数的参数类型
|
|
21
20
|
* @typeParam Instance - 构建函数的返回的实例类型
|
|
21
|
+
* @typeParam Arg - 构建函数的参数类型
|
|
22
22
|
*/
|
|
23
|
-
export type Constructor<Arg extends any[] = any
|
|
23
|
+
export type Constructor<Instance = any, Arg extends any[] = any> = new (...args: Arg) => Instance;
|
|
24
24
|
/**
|
|
25
25
|
* 构造函数的类型接口
|
|
26
|
+
* @typeParam Instance - 构建函数的返回的实例类型
|
|
27
|
+
* @typeParam Arg - 构建函数的参数类型
|
|
26
28
|
*/
|
|
27
|
-
export interface IConstructor<Arg extends any[] = any
|
|
29
|
+
export interface IConstructor<Instance = any, Arg extends any[] = any> {
|
|
28
30
|
new (...args: Arg): Instance;
|
|
29
31
|
}
|
|
30
32
|
/**
|