@lsby/net-core 0.0.22 → 0.0.23
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/cjs/index.d.cts +0 -1
- package/dist/cjs/interface/interface-type.d.cts +1 -2
- package/dist/cjs/interface/interface.d.cts +0 -1
- package/dist/cjs/interface/plug.d.cts +1 -2
- package/dist/cjs/plugin/chinese-path.d.cts +0 -1
- package/dist/cjs/plugin/custom-data.d.cts +0 -1
- package/dist/cjs/plugin/json.d.cts +0 -1
- package/dist/cjs/plugin/urlencoded.d.cts +0 -1
- package/dist/cjs/result/result.d.cts +1 -2
- package/dist/cjs/server/server.d.cts +0 -1
- package/dist/cjs/test/test.d.cts +0 -1
- package/dist/esm/index.d.ts +0 -1
- package/dist/esm/index.js +14 -14
- package/dist/esm/interface/interface-type.d.ts +1 -2
- package/dist/esm/interface/interface.d.ts +0 -1
- package/dist/esm/interface/plug.d.ts +1 -2
- package/dist/esm/plugin/chinese-path.d.ts +0 -1
- package/dist/esm/plugin/custom-data.d.ts +0 -1
- package/dist/esm/plugin/json.d.ts +0 -1
- package/dist/esm/plugin/urlencoded.d.ts +0 -1
- package/dist/esm/result/result.d.ts +1 -2
- package/dist/esm/server/server.d.ts +0 -1
- package/dist/esm/test/test.d.ts +0 -1
- package/package.json +1 -1
- package/dist/cjs/types/type-hold.cjs +0 -30
- package/dist/cjs/types/type-hold.d.cts +0 -3
- package/dist/esm/types/type-hold.d.ts +0 -3
- package/dist/esm/types/type-hold.js +0 -5
package/dist/cjs/index.d.cts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { 类型保持符号 as ______ } from '../types/type-hold.cjs';
|
|
3
2
|
import { 插件项类型 as _____ } from './plug.cjs';
|
|
4
3
|
import 'express';
|
|
5
4
|
|
|
@@ -9,7 +8,7 @@ declare class 接口类型<路径 extends string, 方法 extends 'get' | 'post',
|
|
|
9
8
|
private 插件们;
|
|
10
9
|
private 正确结果;
|
|
11
10
|
private 错误结果;
|
|
12
|
-
|
|
11
|
+
protected readonly 类型保持符号?: [路径, 方法, 插件们, 正确结果类型, 错误结果类型];
|
|
13
12
|
constructor(路径: 路径, 方法: 方法, 插件们: [...插件们], 正确结果: 正确结果类型, 错误结果: 错误结果类型);
|
|
14
13
|
获得路径(): 路径;
|
|
15
14
|
获得方法(): 方法;
|
|
@@ -3,7 +3,6 @@ import { 正确结果 as ____$1, 错误结果 as ____$2 } from '../result/result
|
|
|
3
3
|
import { 接口类型 as ____ } from './interface-type.cjs';
|
|
4
4
|
import { 插件项类型 as _____, 合并插件结果 as ______ } from './plug.cjs';
|
|
5
5
|
import 'express';
|
|
6
|
-
import '../types/type-hold.cjs';
|
|
7
6
|
|
|
8
7
|
declare class 接口<路径 extends string, 方法 extends 'get' | 'post', 插件们 extends Array<_____>, 正确返回类型 extends z.ZodTypeAny, 错误返回类型 extends z.ZodTypeAny> {
|
|
9
8
|
private 接口类型;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { Request, Response } from 'express';
|
|
2
2
|
import { z } from 'zod';
|
|
3
|
-
import { 类型保持符号 as ______ } from '../types/type-hold.cjs';
|
|
4
3
|
|
|
5
4
|
declare class 插件<Obj extends z.AnyZodObject> {
|
|
6
5
|
private 类型;
|
|
7
6
|
private 实现;
|
|
8
|
-
|
|
7
|
+
protected readonly 类型保持符号?: Obj;
|
|
9
8
|
constructor(类型: Obj, 实现: (req: Request, res: Response) => Promise<z.infer<Obj>>);
|
|
10
9
|
获得类型(): typeof this.类型;
|
|
11
10
|
获得实现(): typeof this.实现;
|
|
@@ -2,7 +2,6 @@ import express from 'express';
|
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { 获得接口插件们 as _______$1 } from '../interface/interface-type.cjs';
|
|
4
4
|
import { 插件 as __, 插件项类型 as _____, 取插件内部类型 as _______, 合并插件结果 as ______ } from '../interface/plug.cjs';
|
|
5
|
-
import '../types/type-hold.cjs';
|
|
6
5
|
|
|
7
6
|
declare class JSON解析插件<Result extends z.ZodObject<{
|
|
8
7
|
body: z.AnyZodObject;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { Request, Response } from 'express';
|
|
2
|
-
import { 类型保持符号 as ______ } from '../types/type-hold.cjs';
|
|
3
2
|
|
|
4
3
|
declare abstract class 结果<T> {
|
|
5
|
-
|
|
4
|
+
protected readonly 类型保持符号?: T;
|
|
6
5
|
abstract run(req: Request, res: Response): Promise<void>;
|
|
7
6
|
}
|
|
8
7
|
declare abstract class 正确结果<T> extends 结果<T> {
|
package/dist/cjs/test/test.d.cts
CHANGED
package/dist/esm/index.d.ts
CHANGED
package/dist/esm/index.js
CHANGED
|
@@ -1,9 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
JSON解析插件
|
|
3
|
-
} from "./chunk-B62YPABM.js";
|
|
4
1
|
import {
|
|
5
2
|
表单解析插件
|
|
6
3
|
} from "./chunk-5UUMGDDD.js";
|
|
4
|
+
import {
|
|
5
|
+
正确JSON结果,
|
|
6
|
+
正确结果,
|
|
7
|
+
正确自定义结果,
|
|
8
|
+
结果,
|
|
9
|
+
错误JSON结果,
|
|
10
|
+
错误结果
|
|
11
|
+
} from "./chunk-HARBKRRI.js";
|
|
7
12
|
import {
|
|
8
13
|
测试
|
|
9
14
|
} from "./chunk-I4WZG5LK.js";
|
|
@@ -16,23 +21,18 @@ import {
|
|
|
16
21
|
import {
|
|
17
22
|
接口
|
|
18
23
|
} from "./chunk-KRIDSMPV.js";
|
|
19
|
-
import {
|
|
20
|
-
正确JSON结果,
|
|
21
|
-
正确结果,
|
|
22
|
-
正确自定义结果,
|
|
23
|
-
结果,
|
|
24
|
-
错误JSON结果,
|
|
25
|
-
错误结果
|
|
26
|
-
} from "./chunk-HARBKRRI.js";
|
|
27
|
-
import "./chunk-ZSY7VBEW.js";
|
|
28
|
-
import "./chunk-LVYVPQ5V.js";
|
|
29
|
-
import "./chunk-BZOQHDXK.js";
|
|
30
24
|
import {
|
|
31
25
|
中文路径支持插件
|
|
32
26
|
} from "./chunk-XG4VZZOX.js";
|
|
33
27
|
import {
|
|
34
28
|
自定义数据插件
|
|
35
29
|
} from "./chunk-P6PGPAMW.js";
|
|
30
|
+
import {
|
|
31
|
+
JSON解析插件
|
|
32
|
+
} from "./chunk-B62YPABM.js";
|
|
33
|
+
import "./chunk-ZSY7VBEW.js";
|
|
34
|
+
import "./chunk-LVYVPQ5V.js";
|
|
35
|
+
import "./chunk-BZOQHDXK.js";
|
|
36
36
|
import {
|
|
37
37
|
插件
|
|
38
38
|
} from "./chunk-KSZE2DTR.js";
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { 类型保持符号 as ______ } from '../types/type-hold.js';
|
|
3
2
|
import { 插件项类型 as _____ } from './plug.js';
|
|
4
3
|
import 'express';
|
|
5
4
|
|
|
@@ -9,7 +8,7 @@ declare class 接口类型<路径 extends string, 方法 extends 'get' | 'post',
|
|
|
9
8
|
private 插件们;
|
|
10
9
|
private 正确结果;
|
|
11
10
|
private 错误结果;
|
|
12
|
-
|
|
11
|
+
protected readonly 类型保持符号?: [路径, 方法, 插件们, 正确结果类型, 错误结果类型];
|
|
13
12
|
constructor(路径: 路径, 方法: 方法, 插件们: [...插件们], 正确结果: 正确结果类型, 错误结果: 错误结果类型);
|
|
14
13
|
获得路径(): 路径;
|
|
15
14
|
获得方法(): 方法;
|
|
@@ -3,7 +3,6 @@ import { 正确结果 as ____$1, 错误结果 as ____$2 } from '../result/result
|
|
|
3
3
|
import { 接口类型 as ____ } from './interface-type.js';
|
|
4
4
|
import { 插件项类型 as _____, 合并插件结果 as ______ } from './plug.js';
|
|
5
5
|
import 'express';
|
|
6
|
-
import '../types/type-hold.js';
|
|
7
6
|
|
|
8
7
|
declare class 接口<路径 extends string, 方法 extends 'get' | 'post', 插件们 extends Array<_____>, 正确返回类型 extends z.ZodTypeAny, 错误返回类型 extends z.ZodTypeAny> {
|
|
9
8
|
private 接口类型;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { Request, Response } from 'express';
|
|
2
2
|
import { z } from 'zod';
|
|
3
|
-
import { 类型保持符号 as ______ } from '../types/type-hold.js';
|
|
4
3
|
|
|
5
4
|
declare class 插件<Obj extends z.AnyZodObject> {
|
|
6
5
|
private 类型;
|
|
7
6
|
private 实现;
|
|
8
|
-
|
|
7
|
+
protected readonly 类型保持符号?: Obj;
|
|
9
8
|
constructor(类型: Obj, 实现: (req: Request, res: Response) => Promise<z.infer<Obj>>);
|
|
10
9
|
获得类型(): typeof this.类型;
|
|
11
10
|
获得实现(): typeof this.实现;
|
|
@@ -2,7 +2,6 @@ import express from 'express';
|
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { 获得接口插件们 as _______$1 } from '../interface/interface-type.js';
|
|
4
4
|
import { 插件 as __, 插件项类型 as _____, 取插件内部类型 as _______, 合并插件结果 as ______ } from '../interface/plug.js';
|
|
5
|
-
import '../types/type-hold.js';
|
|
6
5
|
|
|
7
6
|
declare class JSON解析插件<Result extends z.ZodObject<{
|
|
8
7
|
body: z.AnyZodObject;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { Request, Response } from 'express';
|
|
2
|
-
import { 类型保持符号 as ______ } from '../types/type-hold.js';
|
|
3
2
|
|
|
4
3
|
declare abstract class 结果<T> {
|
|
5
|
-
|
|
4
|
+
protected readonly 类型保持符号?: T;
|
|
6
5
|
abstract run(req: Request, res: Response): Promise<void>;
|
|
7
6
|
}
|
|
8
7
|
declare abstract class 正确结果<T> extends 结果<T> {
|
package/dist/esm/test/test.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
|
|
20
|
-
// src/types/type-hold.ts
|
|
21
|
-
var type_hold_exports = {};
|
|
22
|
-
__export(type_hold_exports, {
|
|
23
|
-
\u7C7B\u578B\u4FDD\u6301\u7B26\u53F7: () => \u7C7B\u578B\u4FDD\u6301\u7B26\u53F7
|
|
24
|
-
});
|
|
25
|
-
module.exports = __toCommonJS(type_hold_exports);
|
|
26
|
-
var \u7C7B\u578B\u4FDD\u6301\u7B26\u53F7 = Symbol();
|
|
27
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
28
|
-
0 && (module.exports = {
|
|
29
|
-
\u7C7B\u578B\u4FDD\u6301\u7B26\u53F7
|
|
30
|
-
});
|