@midwayjs/web 2.13.2 → 2.14.2

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 CHANGED
@@ -3,6 +3,47 @@
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
5
 
6
+ ## [2.14.2](https://github.com/midwayjs/midway/compare/v2.14.1...v2.14.2) (2021-12-28)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * generate middleware typings ([#1442](https://github.com/midwayjs/midway/issues/1442)) ([1b2f99b](https://github.com/midwayjs/midway/commit/1b2f99b0fcfa6d87fa216ac9277d9f1240ef26a2))
12
+
13
+
14
+
15
+
16
+
17
+ # [2.14.0](https://github.com/midwayjs/midway/compare/v2.13.5...v2.14.0) (2021-12-06)
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * express routing middleware takes effect at the controller level ([#1364](https://github.com/midwayjs/midway/issues/1364)) ([5d5f299](https://github.com/midwayjs/midway/commit/5d5f2992be116ca71b21f01fd782e3a2ac072496))
23
+
24
+
25
+
26
+
27
+
28
+ ## [2.13.4](https://github.com/midwayjs/midway/compare/v2.13.3...v2.13.4) (2021-10-21)
29
+
30
+ **Note:** Version bump only for package @midwayjs/web
31
+
32
+
33
+
34
+
35
+
36
+ ## [2.13.3](https://github.com/midwayjs/midway/compare/v2.13.2...v2.13.3) (2021-09-28)
37
+
38
+
39
+ ### Features
40
+
41
+ * add view, view-ejs and view-nunjucks ([#1308](https://github.com/midwayjs/midway/issues/1308)) ([2621ae1](https://github.com/midwayjs/midway/commit/2621ae1a82c5c4a4c4347b9bbb4349c8a75bee00))
42
+
43
+
44
+
45
+
46
+
6
47
  ## [2.13.2](https://github.com/midwayjs/midway/compare/v2.13.1...v2.13.2) (2021-09-09)
7
48
 
8
49
  **Note:** Version bump only for package @midwayjs/web
package/README.md CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  this is a sub package for midway.
7
7
 
8
- Document: [https://midwayjs.org/midway](https://midwayjs.org/midway)
8
+ Document: [https://midwayjs.org](https://midwayjs.org)
9
9
 
10
10
  ## License
11
11
 
package/dist/base.js CHANGED
@@ -117,6 +117,9 @@ const createAppWorkerLoader = () => {
117
117
  })
118
118
  .load(this.framework);
119
119
  if (this.app.options['midwaySingleton'] !== true) {
120
+ if (!global['MIDWAY_MAIN_FRAMEWORK']) {
121
+ global['MIDWAY_MAIN_FRAMEWORK'] = this.framework;
122
+ }
120
123
  // 这个代码只会在 egg-cluster 模式下执行
121
124
  this.app.beforeStart(async () => {
122
125
  await this.bootstrap.init();
@@ -8,7 +8,7 @@ export interface IMidwayWebBaseApplication {
8
8
  getLogger(name?: string): EggLogger & ILogger;
9
9
  getCoreLogger(): EggLogger & ILogger;
10
10
  generateController?(controllerMapping: string): any;
11
- generateMiddleware?(middlewareId: string): Promise<Middleware<DefaultState, IMidwayKoaContext>>;
11
+ generateMiddleware?(middlewareId: any): Promise<Middleware<DefaultState, IMidwayKoaContext>>;
12
12
  createLogger(name: string, options: LoggerOptions): EggLogger & ILogger;
13
13
  }
14
14
  declare module 'egg' {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@midwayjs/web",
3
- "version": "2.13.2",
3
+ "version": "2.14.2",
4
4
  "description": "Midway Web Framework for Egg.js",
5
5
  "main": "dist/index",
6
6
  "typings": "dist/index.d.ts",
@@ -27,11 +27,11 @@
27
27
  ],
28
28
  "license": "MIT",
29
29
  "devDependencies": {
30
- "@midwayjs/decorator": "^2.13.2",
31
- "@midwayjs/mock": "^2.13.2",
30
+ "@midwayjs/decorator": "^2.14.0",
31
+ "@midwayjs/mock": "^2.14.0",
32
32
  "dayjs": "^1.10.4",
33
33
  "egg-socket.io": "^4.1.6",
34
- "egg-view-nunjucks": "^2.2.0",
34
+ "egg-view-nunjucks": "^2.3.0",
35
35
  "fake-egg": "1.0.0",
36
36
  "fs-extra": "^8.0.1",
37
37
  "mm": "3",
@@ -41,9 +41,9 @@
41
41
  },
42
42
  "dependencies": {
43
43
  "@eggjs/router": "^2.0.0",
44
- "@midwayjs/bootstrap": "^2.13.2",
45
- "@midwayjs/core": "^2.13.2",
46
- "@midwayjs/koa": "^2.13.2",
44
+ "@midwayjs/bootstrap": "^2.14.0",
45
+ "@midwayjs/core": "^2.14.0",
46
+ "@midwayjs/koa": "^2.14.2",
47
47
  "@midwayjs/logger": "^2.13.0",
48
48
  "debug": "^4.1.1",
49
49
  "egg": "^2.28.0",
@@ -51,7 +51,7 @@
51
51
  "egg-path-matching": "^1.0.1",
52
52
  "extend2": "^1.0.0",
53
53
  "find-up": "^5.0.0",
54
- "midway-schedule": "^2.13.2",
54
+ "midway-schedule": "^2.14.0",
55
55
  "mkdirp": "^1.0.4"
56
56
  },
57
57
  "author": "Harry Chen <czy88840616@gmail.com>",
@@ -62,5 +62,5 @@
62
62
  "engines": {
63
63
  "node": ">=10.10.0"
64
64
  },
65
- "gitHead": "30cec549e5e393fb6ace1cecfb9c122d8ca647d0"
65
+ "gitHead": "68b7fd9182619e8428f353f24a52254abce6e5bf"
66
66
  }