koa 2.12.1 → 2.13.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/History.md +11 -0
- package/dist/koa.mjs +4 -0
- package/lib/application.js +2 -0
- package/lib/response.js +2 -1
- package/package.json +13 -2
package/History.md
CHANGED
|
@@ -1,4 +1,15 @@
|
|
|
1
1
|
|
|
2
|
+
2.13.0 / 2020-06-21
|
|
3
|
+
==================
|
|
4
|
+
|
|
5
|
+
**features**
|
|
6
|
+
* [[`bbcde76`](http://github.com/koajs/koa/commit/bbcde76f5cb5b67bbcd3201791cf0ef648fd3a8b)] - feat: support esm (#1474) (ZYSzys <<zhangyongsheng@youzan.com>>)
|
|
7
|
+
|
|
8
|
+
**others**
|
|
9
|
+
* [[`20e58cf`](http://github.com/koajs/koa/commit/20e58cf3e4f20fc5d5886df1d0ac6dd8c33bd202)] - test: imporve coverage to 100% (dead-horse <<dead_horse@qq.com>>)
|
|
10
|
+
* [[`4a40d63`](http://github.com/koajs/koa/commit/4a40d633c4b4a203c6656078f9952ccef65c5875)] - build: use prepare instead of prepublish (dead-horse <<dead_horse@qq.com>>)
|
|
11
|
+
* [[`226ba8c`](http://github.com/koajs/koa/commit/226ba8c8e81e83da48e7bf137be3f146d03f40b8)] - build: use prepublish instead of prepack (dead-horse <<dead_horse@qq.com>>)
|
|
12
|
+
|
|
2
13
|
2.12.1 / 2020-06-13
|
|
3
14
|
==================
|
|
4
15
|
|
package/dist/koa.mjs
ADDED
package/lib/application.js
CHANGED
|
@@ -59,6 +59,8 @@ module.exports = class Application extends Emitter {
|
|
|
59
59
|
this.context = Object.create(context);
|
|
60
60
|
this.request = Object.create(request);
|
|
61
61
|
this.response = Object.create(response);
|
|
62
|
+
// util.inspect.custom support for node 6+
|
|
63
|
+
/* istanbul ignore else */
|
|
62
64
|
if (util.inspect.custom) {
|
|
63
65
|
this[util.inspect.custom] = this.inspect;
|
|
64
66
|
}
|
package/lib/response.js
CHANGED
|
@@ -572,11 +572,12 @@ module.exports = {
|
|
|
572
572
|
};
|
|
573
573
|
|
|
574
574
|
/**
|
|
575
|
-
* Custom inspection implementation for
|
|
575
|
+
* Custom inspection implementation for node 6+.
|
|
576
576
|
*
|
|
577
577
|
* @return {Object}
|
|
578
578
|
* @api public
|
|
579
579
|
*/
|
|
580
|
+
/* istanbul ignore else */
|
|
580
581
|
if (util.inspect.custom) {
|
|
581
582
|
module.exports[util.inspect.custom] = module.exports.inspect;
|
|
582
583
|
}
|
package/package.json
CHANGED
|
@@ -1,14 +1,23 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "koa",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.13.0",
|
|
4
4
|
"description": "Koa web app framework",
|
|
5
5
|
"main": "lib/application.js",
|
|
6
|
+
"exports": {
|
|
7
|
+
".": {
|
|
8
|
+
"require": "./lib/application.js",
|
|
9
|
+
"import": "./dist/koa.mjs"
|
|
10
|
+
},
|
|
11
|
+
"./": "./"
|
|
12
|
+
},
|
|
6
13
|
"scripts": {
|
|
7
14
|
"test": "egg-bin test test",
|
|
8
15
|
"test-cov": "egg-bin cov test",
|
|
9
16
|
"lint": "eslint benchmarks lib test",
|
|
10
17
|
"bench": "make -C benchmarks",
|
|
11
|
-
"authors": "git log --format='%aN <%aE>' | sort -u > AUTHORS"
|
|
18
|
+
"authors": "git log --format='%aN <%aE>' | sort -u > AUTHORS",
|
|
19
|
+
"build": "gen-esm-wrapper . ./dist/koa.mjs",
|
|
20
|
+
"prepare": "npm run build"
|
|
12
21
|
},
|
|
13
22
|
"repository": "koajs/koa",
|
|
14
23
|
"keywords": [
|
|
@@ -55,6 +64,7 @@
|
|
|
55
64
|
"eslint-plugin-node": "^10.0.0",
|
|
56
65
|
"eslint-plugin-promise": "^4.2.1",
|
|
57
66
|
"eslint-plugin-standard": "^4.0.1",
|
|
67
|
+
"gen-esm-wrapper": "^1.0.6",
|
|
58
68
|
"mm": "^2.5.0",
|
|
59
69
|
"supertest": "^3.1.0"
|
|
60
70
|
},
|
|
@@ -62,6 +72,7 @@
|
|
|
62
72
|
"node": "^4.8.4 || ^6.10.1 || ^7.10.1 || >= 8.1.4"
|
|
63
73
|
},
|
|
64
74
|
"files": [
|
|
75
|
+
"dist",
|
|
65
76
|
"lib"
|
|
66
77
|
]
|
|
67
78
|
}
|