koa-ts-core 0.0.10 → 0.0.11
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/README.md +2 -2
- package/package.json +6 -5
package/README.md
CHANGED
|
@@ -11,7 +11,7 @@ npm i koa-ts-core
|
|
|
11
11
|
宿主项目需要安装库
|
|
12
12
|
|
|
13
13
|
```shell
|
|
14
|
-
npm i koa koa
|
|
14
|
+
npm i koa @koa/router dotenv
|
|
15
15
|
```
|
|
16
16
|
|
|
17
17
|
## 初始化
|
|
@@ -151,7 +151,7 @@ export default Test;
|
|
|
151
151
|
|
|
152
152
|
#### 装饰器实现
|
|
153
153
|
|
|
154
|
-
`@Router`和`@AuthRouter`装饰器本质是基于[koa
|
|
154
|
+
`@Router`和`@AuthRouter`装饰器本质是基于[@koa/router](https://www.npmjs.com/package/@koa/router)进行封装
|
|
155
155
|
|
|
156
156
|
ps:路由参数参考[path-to-regexp](https://github.com/pillarjs/path-to-regexp)
|
|
157
157
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "koa-ts-core",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.11",
|
|
4
4
|
"description": "koa-ts-core",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"module": "dist/index.esm.js",
|
|
@@ -24,10 +24,10 @@
|
|
|
24
24
|
"author": "",
|
|
25
25
|
"license": "ISC",
|
|
26
26
|
"dependencies": {
|
|
27
|
+
"@koa/router": "^14.0.0",
|
|
27
28
|
"dotenv": "^16.4.7",
|
|
28
29
|
"koa": "^2.15.4",
|
|
29
30
|
"koa-bodyparser": "^4.4.1",
|
|
30
|
-
"koa-router": "^13.0.1",
|
|
31
31
|
"portfinder": "^1.0.37",
|
|
32
32
|
"pug": "^3.0.3",
|
|
33
33
|
"rollup-plugin-pug": "^1.1.1"
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"@rollup/plugin-typescript": "^12.1.2",
|
|
41
41
|
"@types/koa": "^2.15.0",
|
|
42
42
|
"@types/koa-bodyparser": "^4.3.12",
|
|
43
|
-
"@types/
|
|
43
|
+
"@types/koa__router": "^12.0.4",
|
|
44
44
|
"@types/node": "^22.13.4",
|
|
45
45
|
"@types/pug": "^2.0.10",
|
|
46
46
|
"rollup": "^4.34.9",
|
|
@@ -51,5 +51,6 @@
|
|
|
51
51
|
},
|
|
52
52
|
"engines": {
|
|
53
53
|
"node": ">=14.0.0"
|
|
54
|
-
}
|
|
55
|
-
|
|
54
|
+
},
|
|
55
|
+
"packageManager": "pnpm@10.13.1+sha512.37ebf1a5c7a30d5fabe0c5df44ee8da4c965ca0c5af3dbab28c3a1681b70a256218d05c81c9c0dcf767ef6b8551eb5b960042b9ed4300c59242336377e01cfad"
|
|
56
|
+
}
|