@eggjs/tegg-plugin 0.1.16 → 1.0.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/CHANGELOG.md +7 -0
- package/app/extend/application.d.ts +5 -1
- package/app/extend/application.js +11 -1
- package/package.json +11 -11
- package/typings/index.d.ts +8 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,3 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
|
+
|
|
6
|
+
# [0.2.0](https://github.com/eggjs/tegg/compare/v0.1.19...v0.2.0) (2022-01-20)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* impl aop ([c53df00](https://github.com/eggjs/tegg/commit/c53df001d1455a0a105689694775d880541d9d2f))
|
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
import { EggPrototype, EggPrototypeCreatorFactory, EggPrototypeFactory, LoadUnitFactory } from '@eggjs/tegg-metadata';
|
|
2
|
-
import { AbstractEggContext, EggContainerFactory, LoadUnitInstanceFactory } from '@eggjs/tegg-runtime';
|
|
2
|
+
import { AbstractEggContext, EggContainerFactory, EggObjectFactory, LoadUnitInstanceFactory } from '@eggjs/tegg-runtime';
|
|
3
|
+
import { LoaderFactory } from '@eggjs/tegg-loader';
|
|
3
4
|
import { EggProtoImplClass, IdenticalUtil } from '@eggjs/tegg';
|
|
4
5
|
declare const _default: {
|
|
5
6
|
readonly eggPrototypeCreatorFactory: typeof EggPrototypeCreatorFactory;
|
|
6
7
|
readonly eggPrototypeFactory: EggPrototypeFactory;
|
|
7
8
|
readonly loadUnitLifecycleUtil: import("@eggjs/tegg").LifecycleUtil<import("@eggjs/tegg-metadata").LoadUnitLifecycleContext, import("@eggjs/tegg-metadata").LoadUnit>;
|
|
8
9
|
readonly loadUnitFactory: typeof LoadUnitFactory;
|
|
10
|
+
readonly eggObjectFactory: typeof EggObjectFactory;
|
|
9
11
|
readonly loadUnitInstanceFactory: typeof LoadUnitInstanceFactory;
|
|
10
12
|
readonly loadUnitInstanceLifecycleUtil: import("@eggjs/tegg").LifecycleUtil<import("@eggjs/tegg-runtime").LoadUnitInstanceLifecycleContext, import("@eggjs/tegg-runtime").LoadUnitInstance>;
|
|
11
13
|
readonly eggContainerFactory: typeof EggContainerFactory;
|
|
14
|
+
readonly loaderFactory: typeof LoaderFactory;
|
|
12
15
|
readonly eggPrototypeLifecycleUtil: import("@eggjs/tegg").LifecycleUtil<import("@eggjs/tegg-metadata").EggPrototypeLifecycleContext, EggPrototype>;
|
|
13
16
|
readonly eggContextLifecycleUtil: import("@eggjs/tegg").LifecycleUtil<import("@eggjs/tegg-runtime").EggContextLifecycleContext, import("@eggjs/tegg-runtime").EggContext>;
|
|
17
|
+
readonly eggObjectLifecycleUtil: import("@eggjs/tegg").LifecycleUtil<import("@eggjs/tegg-runtime").EggObjectLifeCycleContext, import("@eggjs/tegg-runtime").EggObject>;
|
|
14
18
|
readonly abstractEggContext: typeof AbstractEggContext;
|
|
15
19
|
readonly identicalUtil: typeof IdenticalUtil;
|
|
16
20
|
getEggObject(clazz: EggProtoImplClass): Promise<object>;
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tegg_metadata_1 = require("@eggjs/tegg-metadata");
|
|
4
4
|
const tegg_runtime_1 = require("@eggjs/tegg-runtime");
|
|
5
|
+
const tegg_loader_1 = require("@eggjs/tegg-loader");
|
|
5
6
|
const tegg_1 = require("@eggjs/tegg");
|
|
6
7
|
exports.default = {
|
|
7
8
|
// @eggjs/tegg-metadata should not depend by other egg plugins.
|
|
@@ -20,6 +21,9 @@ exports.default = {
|
|
|
20
21
|
get loadUnitFactory() {
|
|
21
22
|
return tegg_metadata_1.LoadUnitFactory;
|
|
22
23
|
},
|
|
24
|
+
get eggObjectFactory() {
|
|
25
|
+
return tegg_runtime_1.EggObjectFactory;
|
|
26
|
+
},
|
|
23
27
|
get loadUnitInstanceFactory() {
|
|
24
28
|
return tegg_runtime_1.LoadUnitInstanceFactory;
|
|
25
29
|
},
|
|
@@ -29,12 +33,18 @@ exports.default = {
|
|
|
29
33
|
get eggContainerFactory() {
|
|
30
34
|
return tegg_runtime_1.EggContainerFactory;
|
|
31
35
|
},
|
|
36
|
+
get loaderFactory() {
|
|
37
|
+
return tegg_loader_1.LoaderFactory;
|
|
38
|
+
},
|
|
32
39
|
get eggPrototypeLifecycleUtil() {
|
|
33
40
|
return tegg_metadata_1.EggPrototypeLifecycleUtil;
|
|
34
41
|
},
|
|
35
42
|
get eggContextLifecycleUtil() {
|
|
36
43
|
return tegg_runtime_1.EggContextLifecycleUtil;
|
|
37
44
|
},
|
|
45
|
+
get eggObjectLifecycleUtil() {
|
|
46
|
+
return tegg_runtime_1.EggObjectLifecycleUtil;
|
|
47
|
+
},
|
|
38
48
|
get abstractEggContext() {
|
|
39
49
|
return tegg_runtime_1.AbstractEggContext;
|
|
40
50
|
},
|
|
@@ -50,4 +60,4 @@ exports.default = {
|
|
|
50
60
|
return eggObject.obj;
|
|
51
61
|
},
|
|
52
62
|
};
|
|
53
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
63
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXBwbGljYXRpb24uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJhcHBsaWNhdGlvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHdEQU84QjtBQUM5QixzREFRNkI7QUFDN0Isb0RBQW1EO0FBQ25ELHNDQUE4RTtBQUU5RSxrQkFBZTtJQUNiLCtEQUErRDtJQUMvRCxzQ0FBc0M7SUFDdEMsNERBQTREO0lBQzVELGtDQUFrQztJQUNsQyxJQUFJLDBCQUEwQjtRQUM1QixPQUFPLDBDQUEwQixDQUF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UssRUFBRTtZQUNWLE1BQU0sSUFBSSxLQUFLLENBQUMsK0JBQStCLEtBQUssQ0FBQyxJQUFJLEVBQUUsQ0FBQyxDQUFDO1NBQzlEO1FBQ0QsTUFBTSxTQUFTLEdBQUcsTUFBTSxrQ0FBbUIsQ0FBQyxvQkFBb0IsQ0FBQyxLQUFxQixDQUFDLENBQUM7UUFDeEYsT0FBTyxTQUFTLENBQUMsR0FBRyxDQUFDO0lBQ3ZCLENBQUM7Q0FDRixDQUFDIn0=
|
package/package.json
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
"teggConfig"
|
|
7
7
|
]
|
|
8
8
|
},
|
|
9
|
-
"version": "0.
|
|
9
|
+
"version": "1.0.0",
|
|
10
10
|
"description": "module plugin for egg",
|
|
11
11
|
"keywords": [
|
|
12
12
|
"egg",
|
|
@@ -45,18 +45,18 @@
|
|
|
45
45
|
"node": ">=14.0.0"
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@eggjs/egg-module-common": "^0.
|
|
49
|
-
"@eggjs/tegg": "^0.
|
|
50
|
-
"@eggjs/tegg-background-task": "^0.
|
|
51
|
-
"@eggjs/tegg-common-util": "^0.
|
|
52
|
-
"@eggjs/tegg-dynamic-inject-runtime": "^0.
|
|
53
|
-
"@eggjs/tegg-loader": "^0.
|
|
54
|
-
"@eggjs/tegg-metadata": "^0.
|
|
55
|
-
"@eggjs/tegg-runtime": "^0.
|
|
48
|
+
"@eggjs/egg-module-common": "^1.0.0",
|
|
49
|
+
"@eggjs/tegg": "^1.0.0",
|
|
50
|
+
"@eggjs/tegg-background-task": "^1.0.0",
|
|
51
|
+
"@eggjs/tegg-common-util": "^1.0.0",
|
|
52
|
+
"@eggjs/tegg-dynamic-inject-runtime": "^1.0.0",
|
|
53
|
+
"@eggjs/tegg-loader": "^1.0.0",
|
|
54
|
+
"@eggjs/tegg-metadata": "^1.0.0",
|
|
55
|
+
"@eggjs/tegg-runtime": "^1.0.0",
|
|
56
56
|
"sdk-base": "^3.6.0"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
|
-
"@eggjs/tegg-config": "^0.
|
|
59
|
+
"@eggjs/tegg-config": "^1.0.0",
|
|
60
60
|
"egg": "^2.26.1",
|
|
61
61
|
"egg-mock": "^3.25.1",
|
|
62
62
|
"egg-tracer": "^1.1.0",
|
|
@@ -65,5 +65,5 @@
|
|
|
65
65
|
"publishConfig": {
|
|
66
66
|
"access": "public"
|
|
67
67
|
},
|
|
68
|
-
"gitHead": "
|
|
68
|
+
"gitHead": "5851321b2488752f6702ff99023b1f70a6541eab"
|
|
69
69
|
}
|
package/typings/index.d.ts
CHANGED
|
@@ -12,8 +12,12 @@ import {
|
|
|
12
12
|
EggContainerFactory,
|
|
13
13
|
LoadUnitInstanceFactory,
|
|
14
14
|
LoadUnitInstanceLifecycleUtil,
|
|
15
|
-
EggContextLifecycleUtil,
|
|
15
|
+
EggContextLifecycleUtil,
|
|
16
|
+
EggObjectLifecycleUtil,
|
|
17
|
+
AbstractEggContext,
|
|
18
|
+
EggObjectFactory,
|
|
16
19
|
} from '@eggjs/tegg-runtime';
|
|
20
|
+
import { LoaderFactory } from '@eggjs/tegg-loader';
|
|
17
21
|
import { IdenticalUtil, EggProtoImplClass } from '@eggjs/tegg';
|
|
18
22
|
|
|
19
23
|
declare module 'egg' {
|
|
@@ -31,14 +35,17 @@ declare module 'egg' {
|
|
|
31
35
|
eggPrototypeFactory: EggPrototypeFactory;
|
|
32
36
|
eggContainerFactory: typeof EggContainerFactory;
|
|
33
37
|
loadUnitFactory: typeof LoadUnitFactory;
|
|
38
|
+
eggObjectFactory: typeof EggObjectFactory;
|
|
34
39
|
loadUnitInstanceFactory: typeof LoadUnitInstanceFactory;
|
|
35
40
|
abstractEggContext: typeof AbstractEggContext;
|
|
36
41
|
identicalUtil: typeof IdenticalUtil;
|
|
42
|
+
loaderFactory: typeof LoaderFactory;
|
|
37
43
|
|
|
38
44
|
loadUnitLifecycleUtil: typeof LoadUnitLifecycleUtil;
|
|
39
45
|
loadUnitInstanceLifecycleUtil: typeof LoadUnitInstanceLifecycleUtil;
|
|
40
46
|
eggPrototypeLifecycleUtil: typeof EggPrototypeLifecycleUtil;
|
|
41
47
|
eggContextLifecycleUtil: typeof EggContextLifecycleUtil;
|
|
48
|
+
eggObjectLifecycleUtil: typeof EggObjectLifecycleUtil;
|
|
42
49
|
|
|
43
50
|
moduleHandler: ModuleHandler;
|
|
44
51
|
|