@eggjs/standalone-decorator 4.0.0-beta.34 → 4.0.0-beta.36
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/decorator/Runner.d.ts +6 -2
- package/dist/decorator/Runner.js +10 -6
- package/dist/index.d.ts +4 -3
- package/dist/index.js +4 -4
- package/dist/typing.d.ts +6 -3
- package/dist/util/StandaloneUtil.d.ts +9 -5
- package/dist/util/StandaloneUtil.js +13 -10
- package/package.json +25 -29
- package/dist/decorator/index.d.ts +0 -1
- package/dist/decorator/index.js +0 -2
- package/dist/typing.js +0 -2
- package/dist/util/index.d.ts +0 -1
- package/dist/util/index.js +0 -2
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
1
|
+
import { MainRunnerClass } from "../typing.js";
|
|
2
|
+
|
|
3
|
+
//#region src/decorator/Runner.d.ts
|
|
4
|
+
declare function Runner<T>(): (clazz: MainRunnerClass<T>) => void;
|
|
5
|
+
//#endregion
|
|
6
|
+
export { Runner };
|
package/dist/decorator/Runner.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
import { StandaloneUtil } from "../util/
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { StandaloneUtil } from "../util/StandaloneUtil.js";
|
|
2
|
+
|
|
3
|
+
//#region src/decorator/Runner.ts
|
|
4
|
+
function Runner() {
|
|
5
|
+
return function(clazz) {
|
|
6
|
+
StandaloneUtil.setMainRunner(clazz);
|
|
7
|
+
};
|
|
6
8
|
}
|
|
7
|
-
|
|
9
|
+
|
|
10
|
+
//#endregion
|
|
11
|
+
export { Runner };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { MainRunner, MainRunnerClass } from "./typing.js";
|
|
2
|
+
import { StandaloneUtil } from "./util/StandaloneUtil.js";
|
|
3
|
+
import { Runner } from "./decorator/Runner.js";
|
|
4
|
+
export { MainRunner, MainRunnerClass, Runner, StandaloneUtil };
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { StandaloneUtil } from "./util/StandaloneUtil.js";
|
|
2
|
+
import { Runner } from "./decorator/Runner.js";
|
|
3
|
+
|
|
4
|
+
export { Runner, StandaloneUtil };
|
package/dist/typing.d.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
//#region src/typing.d.ts
|
|
2
|
+
interface MainRunner<T = void> {
|
|
3
|
+
main(): Promise<T>;
|
|
3
4
|
}
|
|
4
|
-
|
|
5
|
+
type MainRunnerClass<T = void> = new () => MainRunner<T>;
|
|
6
|
+
//#endregion
|
|
7
|
+
export { MainRunner, MainRunnerClass };
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { MainRunnerClass } from "../typing.js";
|
|
2
|
+
|
|
3
|
+
//#region src/util/StandaloneUtil.d.ts
|
|
4
|
+
declare class StandaloneUtil {
|
|
5
|
+
private static runnerClass;
|
|
6
|
+
static setMainRunner(runnerClass: MainRunnerClass): void;
|
|
7
|
+
static getMainRunner(): MainRunnerClass | undefined;
|
|
6
8
|
}
|
|
9
|
+
//#endregion
|
|
10
|
+
export { StandaloneUtil };
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
-
|
|
1
|
+
//#region src/util/StandaloneUtil.ts
|
|
2
|
+
var StandaloneUtil = class StandaloneUtil {
|
|
3
|
+
static runnerClass;
|
|
4
|
+
static setMainRunner(runnerClass) {
|
|
5
|
+
StandaloneUtil.runnerClass = runnerClass;
|
|
6
|
+
}
|
|
7
|
+
static getMainRunner() {
|
|
8
|
+
return StandaloneUtil.runnerClass;
|
|
9
|
+
}
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
//#endregion
|
|
13
|
+
export { StandaloneUtil };
|
package/package.json
CHANGED
|
@@ -1,52 +1,48 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eggjs/standalone-decorator",
|
|
3
|
-
"version": "4.0.0-beta.
|
|
3
|
+
"version": "4.0.0-beta.36",
|
|
4
4
|
"description": "tegg standalone decorator",
|
|
5
5
|
"keywords": [
|
|
6
|
-
"egg",
|
|
7
|
-
"typescript",
|
|
8
6
|
"decorator",
|
|
7
|
+
"egg",
|
|
8
|
+
"standalone",
|
|
9
9
|
"tegg",
|
|
10
|
-
"
|
|
11
|
-
],
|
|
12
|
-
"type": "module",
|
|
13
|
-
"exports": {
|
|
14
|
-
".": "./dist/index.js",
|
|
15
|
-
"./package.json": "./package.json"
|
|
16
|
-
},
|
|
17
|
-
"files": [
|
|
18
|
-
"dist"
|
|
10
|
+
"typescript"
|
|
19
11
|
],
|
|
20
|
-
"author": "killagu <killa123@126.com>",
|
|
21
|
-
"license": "MIT",
|
|
22
12
|
"homepage": "https://github.com/eggjs/egg/tree/next/tegg/core/standalone-decorator",
|
|
23
13
|
"bugs": {
|
|
24
14
|
"url": "https://github.com/eggjs/egg/issues"
|
|
25
15
|
},
|
|
16
|
+
"license": "MIT",
|
|
17
|
+
"author": "killagu <killa123@126.com>",
|
|
26
18
|
"repository": {
|
|
27
19
|
"type": "git",
|
|
28
|
-
"url": "git
|
|
20
|
+
"url": "git+https://github.com/eggjs/egg.git",
|
|
29
21
|
"directory": "tegg/core/standalone-decorator"
|
|
30
22
|
},
|
|
31
|
-
"
|
|
32
|
-
"
|
|
23
|
+
"files": [
|
|
24
|
+
"dist"
|
|
25
|
+
],
|
|
26
|
+
"type": "module",
|
|
27
|
+
"main": "./dist/index.js",
|
|
28
|
+
"module": "./dist/index.js",
|
|
29
|
+
"types": "./dist/index.d.ts",
|
|
30
|
+
"exports": {
|
|
31
|
+
".": "./dist/index.js",
|
|
32
|
+
"./package.json": "./package.json"
|
|
33
|
+
},
|
|
34
|
+
"publishConfig": {
|
|
35
|
+
"access": "public"
|
|
33
36
|
},
|
|
34
37
|
"dependencies": {},
|
|
35
38
|
"devDependencies": {
|
|
36
|
-
"@types/node": "^24.
|
|
37
|
-
"typescript": "^5.9.3"
|
|
38
|
-
"tsdown": "0.15.11",
|
|
39
|
-
"unplugin-unused": "^0.5.4"
|
|
39
|
+
"@types/node": "^24.10.2",
|
|
40
|
+
"typescript": "^5.9.3"
|
|
40
41
|
},
|
|
41
|
-
"
|
|
42
|
-
"
|
|
42
|
+
"engines": {
|
|
43
|
+
"node": ">=22.18.0"
|
|
43
44
|
},
|
|
44
|
-
"main": "./dist/index.js",
|
|
45
|
-
"module": "./dist/index.js",
|
|
46
|
-
"types": "./dist/index.d.ts",
|
|
47
45
|
"scripts": {
|
|
48
|
-
"
|
|
49
|
-
"build": "tsdown && npm run clean && tsc -p tsconfig.build.json",
|
|
50
|
-
"typecheck": "tsc --noEmit"
|
|
46
|
+
"typecheck": "tsgo --noEmit"
|
|
51
47
|
}
|
|
52
48
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './Runner.ts';
|
package/dist/decorator/index.js
DELETED
package/dist/typing.js
DELETED
package/dist/util/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './StandaloneUtil.ts';
|
package/dist/util/index.js
DELETED