@mojojs/core 1.4.0 → 1.4.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/lib/app.d.ts +11 -10
- package/package.json +2 -2
package/lib/app.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { Route } from './router/route.js';
|
|
2
|
+
import type { AnyArguments, AppOptions, UserAgentOptions, MojoAction, MojoContext, MojoModels, RouteArguments, ServerOptions, TestUserAgentOptions } from './types.js';
|
|
2
3
|
import { CLI } from './cli.js';
|
|
3
4
|
import { Hooks } from './hooks.js';
|
|
4
5
|
import { Logger } from './logger.js';
|
|
@@ -110,7 +111,7 @@ export declare class App {
|
|
|
110
111
|
/**
|
|
111
112
|
* Generate route matching any of the listed HTTP request methods or all.
|
|
112
113
|
*/
|
|
113
|
-
any(...args: AnyArguments):
|
|
114
|
+
any(...args: AnyArguments): Route;
|
|
114
115
|
/**
|
|
115
116
|
* Decorate context class with a method or getter/setter.
|
|
116
117
|
*/
|
|
@@ -118,11 +119,11 @@ export declare class App {
|
|
|
118
119
|
/**
|
|
119
120
|
* Generate route matching only `DELETE` requests.
|
|
120
121
|
*/
|
|
121
|
-
delete(...args: RouteArguments):
|
|
122
|
+
delete(...args: RouteArguments): Route;
|
|
122
123
|
/**
|
|
123
124
|
* Generate route matching only `GET` requests.
|
|
124
125
|
*/
|
|
125
|
-
get(...args: RouteArguments):
|
|
126
|
+
get(...args: RouteArguments): Route;
|
|
126
127
|
/**
|
|
127
128
|
* Handle a new incoming request, used by servers.
|
|
128
129
|
*/
|
|
@@ -154,11 +155,11 @@ export declare class App {
|
|
|
154
155
|
/**
|
|
155
156
|
* Generate route matching only `OPTIONS` requests.
|
|
156
157
|
*/
|
|
157
|
-
options(...args: RouteArguments):
|
|
158
|
+
options(...args: RouteArguments): Route;
|
|
158
159
|
/**
|
|
159
160
|
* Generate route matching only `PATCH` requests.
|
|
160
161
|
*/
|
|
161
|
-
patch(...args: RouteArguments):
|
|
162
|
+
patch(...args: RouteArguments): Route;
|
|
162
163
|
/**
|
|
163
164
|
* Register plugin.
|
|
164
165
|
*/
|
|
@@ -166,11 +167,11 @@ export declare class App {
|
|
|
166
167
|
/**
|
|
167
168
|
* Generate route matching only `POST` requests.
|
|
168
169
|
*/
|
|
169
|
-
post(...args: RouteArguments):
|
|
170
|
+
post(...args: RouteArguments): Route;
|
|
170
171
|
/**
|
|
171
172
|
* Generate route matching only `PUT` requests.
|
|
172
173
|
*/
|
|
173
|
-
put(...args: RouteArguments):
|
|
174
|
+
put(...args: RouteArguments): Route;
|
|
174
175
|
/**
|
|
175
176
|
* Start the command line interface.
|
|
176
177
|
*/
|
|
@@ -178,7 +179,7 @@ export declare class App {
|
|
|
178
179
|
/**
|
|
179
180
|
* Generate route for a nested route with its own intermediate destination.
|
|
180
181
|
*/
|
|
181
|
-
under(...args: AnyArguments):
|
|
182
|
+
under(...args: AnyArguments): Route;
|
|
182
183
|
/**
|
|
183
184
|
* Warmup the cache, usually called automatically.
|
|
184
185
|
*/
|
|
@@ -186,6 +187,6 @@ export declare class App {
|
|
|
186
187
|
/**
|
|
187
188
|
* Generate route matching only WebSocket handshake requests.
|
|
188
189
|
*/
|
|
189
|
-
websocket(...args: RouteArguments):
|
|
190
|
+
websocket(...args: RouteArguments): Route;
|
|
190
191
|
}
|
|
191
192
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mojojs/core",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.1",
|
|
4
4
|
"description": "Real-time web framework",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"mojojs",
|
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
"@mojojs/dom": "^1.4.0",
|
|
83
83
|
"@mojojs/path": "^1.4.0",
|
|
84
84
|
"@mojojs/template": "^2.1.0",
|
|
85
|
-
"@mojojs/util": "^1.
|
|
85
|
+
"@mojojs/util": "^1.4.1",
|
|
86
86
|
"ajv": "^8.5.0",
|
|
87
87
|
"busboy": "^1.0.0",
|
|
88
88
|
"chalk": "^5.0.0",
|