@onreza/adapter-nitro 0.2.2 → 0.3.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/README.md +44 -5
- package/dist/image/index.d.ts +30 -0
- package/dist/image/index.js +1 -0
- package/dist/image/provider.d.ts +107 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/preset/preset.js +1 -1
- package/dist/routes.d.ts +4 -4
- package/dist/types.d.ts +0 -19
- package/package.json +5 -1
package/dist/routes.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type { Route } from "@onreza/shared";
|
|
2
|
-
import type { NitroRouteConfig } from "nitropack";
|
|
3
|
-
import type { NitroPrerenderedRoute, NitroScannedHandler } from "./types.ts";
|
|
2
|
+
import type { NitroEventHandler, NitroRouteConfig, PrerenderRoute } from "nitropack";
|
|
4
3
|
declare function routeToRegex(route: string): string;
|
|
5
4
|
export interface CollectRoutesParams {
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
assetsPrefix: string;
|
|
6
|
+
handlers: NitroEventHandler[];
|
|
7
|
+
prerenderedRoutes?: PrerenderRoute[];
|
|
8
8
|
routeRules: Record<string, NitroRouteConfig>;
|
|
9
9
|
}
|
|
10
10
|
export declare function collectRoutes(params: CollectRoutesParams): Route[];
|
package/dist/types.d.ts
CHANGED
|
@@ -1,22 +1,3 @@
|
|
|
1
|
-
import type { NitroRouteConfig } from "nitropack";
|
|
2
|
-
export interface NitroScannedHandler {
|
|
3
|
-
handler: string;
|
|
4
|
-
lazy?: boolean;
|
|
5
|
-
method?: string;
|
|
6
|
-
middleware?: boolean;
|
|
7
|
-
route: string;
|
|
8
|
-
}
|
|
9
|
-
export interface NitroPrerenderedRoute {
|
|
10
|
-
contentType?: string;
|
|
11
|
-
contents?: string;
|
|
12
|
-
data?: unknown;
|
|
13
|
-
error?: Error;
|
|
14
|
-
fileName?: string;
|
|
15
|
-
generateTimeMS?: number;
|
|
16
|
-
route: string;
|
|
17
|
-
skip?: boolean;
|
|
18
|
-
}
|
|
19
|
-
export type NitroRouteRules = Record<string, NitroRouteConfig>;
|
|
20
1
|
export interface OnrezaRoute {
|
|
21
2
|
pattern: string;
|
|
22
3
|
priority: number;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@onreza/adapter-nitro",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "ONREZA Nitro adapter for Nuxt, Analog, Vinxi and standalone Nitro",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "ONREZA OSS <opensource@onreza.ru>",
|
|
@@ -13,6 +13,10 @@
|
|
|
13
13
|
"./types": {
|
|
14
14
|
"import": "./dist/index.js",
|
|
15
15
|
"types": "./dist/index.d.ts"
|
|
16
|
+
},
|
|
17
|
+
"./image": {
|
|
18
|
+
"types": "./dist/image/index.d.ts",
|
|
19
|
+
"import": "./dist/image/index.js"
|
|
16
20
|
}
|
|
17
21
|
},
|
|
18
22
|
"main": "./dist/index.js",
|