phecda-server 6.0.0 → 6.0.1
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/{chunk-2UTKBEZE.mjs → chunk-F3W3NN7F.mjs} +5 -0
- package/dist/{chunk-PALEEADE.js → chunk-XCND2QW3.js} +6 -1
- package/dist/index.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +6 -4
- package/dist/index.mjs +4 -2
- package/dist/server/elysia/index.js +2 -2
- package/dist/server/elysia/index.mjs +1 -1
- package/dist/server/fastify/index.js +2 -2
- package/dist/server/fastify/index.mjs +1 -1
- package/package.json +1 -1
|
@@ -131,6 +131,10 @@ function Put(route = "") {
|
|
|
131
131
|
return Route(route, "put");
|
|
132
132
|
}
|
|
133
133
|
__name(Put, "Put");
|
|
134
|
+
function Search(route = "") {
|
|
135
|
+
return Route(route, "search");
|
|
136
|
+
}
|
|
137
|
+
__name(Search, "Search");
|
|
134
138
|
function Patch(route = "") {
|
|
135
139
|
return Route(route, "patch");
|
|
136
140
|
}
|
|
@@ -223,6 +227,7 @@ export {
|
|
|
223
227
|
Get,
|
|
224
228
|
Post,
|
|
225
229
|
Put,
|
|
230
|
+
Search,
|
|
226
231
|
Patch,
|
|
227
232
|
Delete,
|
|
228
233
|
Controller,
|
|
@@ -131,6 +131,10 @@ function Put(route = "") {
|
|
|
131
131
|
return Route(route, "put");
|
|
132
132
|
}
|
|
133
133
|
_chunkGHFSIZUOjs.__name.call(void 0, Put, "Put");
|
|
134
|
+
function Search(route = "") {
|
|
135
|
+
return Route(route, "search");
|
|
136
|
+
}
|
|
137
|
+
_chunkGHFSIZUOjs.__name.call(void 0, Search, "Search");
|
|
134
138
|
function Patch(route = "") {
|
|
135
139
|
return Route(route, "patch");
|
|
136
140
|
}
|
|
@@ -230,4 +234,5 @@ _chunkGHFSIZUOjs.__name.call(void 0, Define, "Define");
|
|
|
230
234
|
|
|
231
235
|
|
|
232
236
|
|
|
233
|
-
|
|
237
|
+
|
|
238
|
+
exports.BaseParam = BaseParam; exports.Body = Body; exports.Head = Head; exports.Query = Query; exports.Param = Param; exports.Arg = Arg; exports.Guard = Guard; exports.Plugin = Plugin; exports.Interceptor = Interceptor; exports.Filter = Filter; exports.Pipe = Pipe; exports.Route = Route; exports.Header = Header; exports.Get = Get; exports.Post = Post; exports.Put = Put; exports.Search = Search; exports.Patch = Patch; exports.Delete = Delete; exports.Controller = Controller; exports.Queue = Queue; exports.Rpc = Rpc; exports.Ctx = Ctx; exports.Define = Define;
|
package/dist/index.d.mts
CHANGED
|
@@ -164,6 +164,7 @@ declare function Header(headers: Record<string, string>): MethodDecorator;
|
|
|
164
164
|
declare function Get(route?: string): MethodDecorator;
|
|
165
165
|
declare function Post(route?: string): MethodDecorator;
|
|
166
166
|
declare function Put(route?: string): MethodDecorator;
|
|
167
|
+
declare function Search(route?: string): MethodDecorator;
|
|
167
168
|
declare function Patch(route?: string): MethodDecorator;
|
|
168
169
|
declare function Delete(route?: string): MethodDecorator;
|
|
169
170
|
declare function Controller(prefix?: string): (target: any) => void;
|
|
@@ -246,4 +247,4 @@ type LogLevel = 'error' | 'info' | 'warn' | 'log';
|
|
|
246
247
|
declare function setLogger(logger: Record<LogLevel, (msg: string) => void>): void;
|
|
247
248
|
declare function log(msg: string, level?: LogLevel): void;
|
|
248
249
|
|
|
249
|
-
export { Arg, BadGatewayException, BadRequestException, BaseContext, BaseError, BaseParam, Body, ConflictException, Context, Controller, ControllerMetaData, Ctx, DefaultOptions, Define, Delete, Emitter, Exception, Filter, type FilterType, ForbiddenException, FrameworkException, Generator, Get, Guard, type GuardType, HTTPGenerator, Head, Header, HttpBase, HttpContext, Interceptor, type InterceptorType, InvalidInputException, MetaData, NotFoundException, PExtension, PFilter, PGuard, PInterceptor, PPipe, PPlugin, Param, Patch, PayloadLargeException, Pipe, type PipeArg, type PipeType, Plugin, Post, Put, Query, Queue, RPCGenerator, Route, Rpc, RpcBase, RpcContext, ServerBase, ServiceUnavailableException, TimeoutException, TimerException, UnauthorizedException, UndefinedException, UnsupportedMediaTypeException, ValidateException, WorkerException, addFilter, addGuard, addInterceptor, addPipe, addPlugin, defaultPipe, log, setLogger };
|
|
250
|
+
export { Arg, BadGatewayException, BadRequestException, BaseContext, BaseError, BaseParam, Body, ConflictException, Context, Controller, ControllerMetaData, Ctx, DefaultOptions, Define, Delete, Emitter, Exception, Filter, type FilterType, ForbiddenException, FrameworkException, Generator, Get, Guard, type GuardType, HTTPGenerator, Head, Header, HttpBase, HttpContext, Interceptor, type InterceptorType, InvalidInputException, MetaData, NotFoundException, PExtension, PFilter, PGuard, PInterceptor, PPipe, PPlugin, Param, Patch, PayloadLargeException, Pipe, type PipeArg, type PipeType, Plugin, Post, Put, Query, Queue, RPCGenerator, Route, Rpc, RpcBase, RpcContext, Search, ServerBase, ServiceUnavailableException, TimeoutException, TimerException, UnauthorizedException, UndefinedException, UnsupportedMediaTypeException, ValidateException, WorkerException, addFilter, addGuard, addInterceptor, addPipe, addPlugin, defaultPipe, log, setLogger };
|
package/dist/index.d.ts
CHANGED
|
@@ -164,6 +164,7 @@ declare function Header(headers: Record<string, string>): MethodDecorator;
|
|
|
164
164
|
declare function Get(route?: string): MethodDecorator;
|
|
165
165
|
declare function Post(route?: string): MethodDecorator;
|
|
166
166
|
declare function Put(route?: string): MethodDecorator;
|
|
167
|
+
declare function Search(route?: string): MethodDecorator;
|
|
167
168
|
declare function Patch(route?: string): MethodDecorator;
|
|
168
169
|
declare function Delete(route?: string): MethodDecorator;
|
|
169
170
|
declare function Controller(prefix?: string): (target: any) => void;
|
|
@@ -246,4 +247,4 @@ type LogLevel = 'error' | 'info' | 'warn' | 'log';
|
|
|
246
247
|
declare function setLogger(logger: Record<LogLevel, (msg: string) => void>): void;
|
|
247
248
|
declare function log(msg: string, level?: LogLevel): void;
|
|
248
249
|
|
|
249
|
-
export { Arg, BadGatewayException, BadRequestException, BaseContext, BaseError, BaseParam, Body, ConflictException, Context, Controller, ControllerMetaData, Ctx, DefaultOptions, Define, Delete, Emitter, Exception, Filter, type FilterType, ForbiddenException, FrameworkException, Generator, Get, Guard, type GuardType, HTTPGenerator, Head, Header, HttpBase, HttpContext, Interceptor, type InterceptorType, InvalidInputException, MetaData, NotFoundException, PExtension, PFilter, PGuard, PInterceptor, PPipe, PPlugin, Param, Patch, PayloadLargeException, Pipe, type PipeArg, type PipeType, Plugin, Post, Put, Query, Queue, RPCGenerator, Route, Rpc, RpcBase, RpcContext, ServerBase, ServiceUnavailableException, TimeoutException, TimerException, UnauthorizedException, UndefinedException, UnsupportedMediaTypeException, ValidateException, WorkerException, addFilter, addGuard, addInterceptor, addPipe, addPlugin, defaultPipe, log, setLogger };
|
|
250
|
+
export { Arg, BadGatewayException, BadRequestException, BaseContext, BaseError, BaseParam, Body, ConflictException, Context, Controller, ControllerMetaData, Ctx, DefaultOptions, Define, Delete, Emitter, Exception, Filter, type FilterType, ForbiddenException, FrameworkException, Generator, Get, Guard, type GuardType, HTTPGenerator, Head, Header, HttpBase, HttpContext, Interceptor, type InterceptorType, InvalidInputException, MetaData, NotFoundException, PExtension, PFilter, PGuard, PInterceptor, PPipe, PPlugin, Param, Patch, PayloadLargeException, Pipe, type PipeArg, type PipeType, Plugin, Post, Put, Query, Queue, RPCGenerator, Route, Rpc, RpcBase, RpcContext, Search, ServerBase, ServiceUnavailableException, TimeoutException, TimerException, UnauthorizedException, UndefinedException, UnsupportedMediaTypeException, ValidateException, WorkerException, addFilter, addGuard, addInterceptor, addPipe, addPlugin, defaultPipe, log, setLogger };
|
package/dist/index.js
CHANGED
|
@@ -29,7 +29,8 @@ var _chunkLYEZ6RGXjs = require('./chunk-LYEZ6RGX.js');
|
|
|
29
29
|
|
|
30
30
|
|
|
31
31
|
|
|
32
|
-
|
|
32
|
+
|
|
33
|
+
var _chunkXCND2QW3js = require('./chunk-XCND2QW3.js');
|
|
33
34
|
|
|
34
35
|
|
|
35
36
|
|
|
@@ -104,7 +105,7 @@ var HttpBase = class extends ServerBase {
|
|
|
104
105
|
|
|
105
106
|
};
|
|
106
107
|
_ts_decorate([
|
|
107
|
-
|
|
108
|
+
_chunkXCND2QW3js.Ctx,
|
|
108
109
|
_ts_metadata("design:type", typeof HttpContext === "undefined" ? Object : HttpContext)
|
|
109
110
|
], HttpBase.prototype, "context", void 0);
|
|
110
111
|
var RpcBase = class extends ServerBase {
|
|
@@ -114,7 +115,7 @@ var RpcBase = class extends ServerBase {
|
|
|
114
115
|
|
|
115
116
|
};
|
|
116
117
|
_ts_decorate([
|
|
117
|
-
|
|
118
|
+
_chunkXCND2QW3js.Ctx,
|
|
118
119
|
_ts_metadata("design:type", typeof RpcContext === "undefined" ? Object : RpcContext)
|
|
119
120
|
], RpcBase.prototype, "context", void 0);
|
|
120
121
|
|
|
@@ -418,4 +419,5 @@ return ret
|
|
|
418
419
|
|
|
419
420
|
|
|
420
421
|
|
|
421
|
-
|
|
422
|
+
|
|
423
|
+
exports.Arg = _chunkXCND2QW3js.Arg; exports.BadGatewayException = _chunkTZYATAJXjs.BadGatewayException; exports.BadRequestException = _chunkTZYATAJXjs.BadRequestException; exports.BaseParam = _chunkXCND2QW3js.BaseParam; exports.Body = _chunkXCND2QW3js.Body; exports.ConflictException = _chunkTZYATAJXjs.ConflictException; exports.Context = _chunkTZYATAJXjs.Context; exports.Controller = _chunkXCND2QW3js.Controller; exports.Ctx = _chunkXCND2QW3js.Ctx; exports.CustomResponse = CustomResponse; exports.Define = _chunkXCND2QW3js.Define; exports.Delete = _chunkXCND2QW3js.Delete; exports.ERROR_SYMBOL = _chunkGHFSIZUOjs.ERROR_SYMBOL; exports.Exception = _chunkTZYATAJXjs.Exception; exports.Factory = _chunkLYEZ6RGXjs.Factory; exports.Filter = _chunkXCND2QW3js.Filter; exports.ForbiddenException = _chunkTZYATAJXjs.ForbiddenException; exports.FrameworkException = _chunkTZYATAJXjs.FrameworkException; exports.Generator = Generator; exports.Get = _chunkXCND2QW3js.Get; exports.Guard = _chunkXCND2QW3js.Guard; exports.HTTPGenerator = HTTPGenerator; exports.Head = _chunkXCND2QW3js.Head; exports.Header = _chunkXCND2QW3js.Header; exports.HttpBase = HttpBase; exports.IS_HMR = _chunkGHFSIZUOjs.IS_HMR; exports.IS_ONLY_GENERATE = _chunkGHFSIZUOjs.IS_ONLY_GENERATE; exports.IS_STRICT = _chunkGHFSIZUOjs.IS_STRICT; exports.Interceptor = _chunkXCND2QW3js.Interceptor; exports.InvalidInputException = _chunkTZYATAJXjs.InvalidInputException; exports.LOG_LEVEL = _chunkGHFSIZUOjs.LOG_LEVEL; exports.Meta = _chunkLYEZ6RGXjs.Meta; exports.Mixin = _chunkGHFSIZUOjs.Mixin; exports.NotFoundException = _chunkTZYATAJXjs.NotFoundException; exports.PExtension = PExtension; exports.PFilter = PFilter; exports.PGuard = PGuard; exports.PInterceptor = PInterceptor; exports.PPipe = PPipe; exports.PPlugin = PPlugin; exports.PS_EXIT_CODE = _chunkGHFSIZUOjs.PS_EXIT_CODE; exports.Param = _chunkXCND2QW3js.Param; exports.Patch = _chunkXCND2QW3js.Patch; exports.PayloadLargeException = _chunkTZYATAJXjs.PayloadLargeException; exports.Pipe = _chunkXCND2QW3js.Pipe; exports.Plugin = _chunkXCND2QW3js.Plugin; exports.Post = _chunkXCND2QW3js.Post; exports.Put = _chunkXCND2QW3js.Put; exports.Query = _chunkXCND2QW3js.Query; exports.Queue = _chunkXCND2QW3js.Queue; exports.RPCGenerator = RPCGenerator; exports.Route = _chunkXCND2QW3js.Route; exports.Rpc = _chunkXCND2QW3js.Rpc; exports.RpcBase = RpcBase; exports.Search = _chunkXCND2QW3js.Search; exports.ServerBase = ServerBase; exports.ServiceUnavailableException = _chunkTZYATAJXjs.ServiceUnavailableException; exports.TimeoutException = _chunkTZYATAJXjs.TimeoutException; exports.TimerException = _chunkTZYATAJXjs.TimerException; exports.UnauthorizedException = _chunkTZYATAJXjs.UnauthorizedException; exports.UndefinedException = _chunkTZYATAJXjs.UndefinedException; exports.UnsupportedMediaTypeException = _chunkTZYATAJXjs.UnsupportedMediaTypeException; exports.ValidateException = _chunkTZYATAJXjs.ValidateException; exports.WorkerException = _chunkTZYATAJXjs.WorkerException; exports.addFilter = _chunkTZYATAJXjs.addFilter; exports.addGuard = _chunkTZYATAJXjs.addGuard; exports.addInterceptor = _chunkTZYATAJXjs.addInterceptor; exports.addPipe = _chunkTZYATAJXjs.addPipe; exports.addPlugin = _chunkTZYATAJXjs.addPlugin; exports.createPhecda = _chunkLYEZ6RGXjs.createPhecda; exports.defaultPipe = _chunkTZYATAJXjs.defaultPipe; exports.emitter = _chunkLYEZ6RGXjs.emitter; exports.isObject = _chunkLYEZ6RGXjs.isObject; exports.log = _chunkGHFSIZUOjs.log; exports.setLogger = _chunkGHFSIZUOjs.setLogger;
|
package/dist/index.mjs
CHANGED
|
@@ -28,8 +28,9 @@ import {
|
|
|
28
28
|
Query,
|
|
29
29
|
Queue,
|
|
30
30
|
Route,
|
|
31
|
-
Rpc
|
|
32
|
-
|
|
31
|
+
Rpc,
|
|
32
|
+
Search
|
|
33
|
+
} from "./chunk-F3W3NN7F.mjs";
|
|
33
34
|
import {
|
|
34
35
|
BadGatewayException,
|
|
35
36
|
BadRequestException,
|
|
@@ -398,6 +399,7 @@ export {
|
|
|
398
399
|
Route,
|
|
399
400
|
Rpc,
|
|
400
401
|
RpcBase,
|
|
402
|
+
Search,
|
|
401
403
|
ServerBase,
|
|
402
404
|
ServiceUnavailableException,
|
|
403
405
|
TimeoutException,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkXCND2QW3js = require('../../chunk-XCND2QW3.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -147,7 +147,7 @@ function bind(app, data, opts = {}) {
|
|
|
147
147
|
}
|
|
148
148
|
_chunkGHFSIZUOjs.__name.call(void 0, bind, "bind");
|
|
149
149
|
function Elysia(opts) {
|
|
150
|
-
return
|
|
150
|
+
return _chunkXCND2QW3js.Define.call(void 0, "elysia", opts);
|
|
151
151
|
}
|
|
152
152
|
_chunkGHFSIZUOjs.__name.call(void 0, Elysia, "Elysia");
|
|
153
153
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkXCND2QW3js = require('../../chunk-XCND2QW3.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -162,7 +162,7 @@ function bind(fastify, data, opts = {}) {
|
|
|
162
162
|
}
|
|
163
163
|
_chunkGHFSIZUOjs.__name.call(void 0, bind, "bind");
|
|
164
164
|
function Fastify(opts) {
|
|
165
|
-
return
|
|
165
|
+
return _chunkXCND2QW3js.Define.call(void 0, "fastify", opts);
|
|
166
166
|
}
|
|
167
167
|
_chunkGHFSIZUOjs.__name.call(void 0, Fastify, "Fastify");
|
|
168
168
|
|