@arkstack/contract 0.1.30 → 0.2.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/global.d.ts +9 -0
- package/dist/index.d.ts +1 -8
- package/package.json +4 -6
package/dist/global.d.ts
ADDED
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference path="./global.d.ts" />
|
|
1
2
|
//#region src/index.d.ts
|
|
2
3
|
type PromiseOrValue<T> = T | Promise<T>;
|
|
3
4
|
interface ArkstackMiddlewareConfig<TMiddleware> {
|
|
@@ -16,10 +17,6 @@ interface ArkstackRouterAwareCore<TApp, TRoutes = unknown> {
|
|
|
16
17
|
getAppInstance(): TApp;
|
|
17
18
|
getRouter(): ArkstackRouterContract<TApp, TRoutes>;
|
|
18
19
|
}
|
|
19
|
-
/**
|
|
20
|
-
* The ArkstackKitDriver class defines the contract for a driver
|
|
21
|
-
* that can be used with the ArkstackKitContract.
|
|
22
|
-
*/
|
|
23
20
|
declare abstract class ArkstackKitDriver<TApp, TMiddleware> {
|
|
24
21
|
abstract readonly name: string;
|
|
25
22
|
abstract createApp(): TApp;
|
|
@@ -29,10 +26,6 @@ declare abstract class ArkstackKitDriver<TApp, TMiddleware> {
|
|
|
29
26
|
registerErrorHandler(_app: TApp): PromiseOrValue<void>;
|
|
30
27
|
abstract start(app: TApp, port: number): PromiseOrValue<void>;
|
|
31
28
|
}
|
|
32
|
-
/**
|
|
33
|
-
* The ArkstackKitContract class defines the contract for an
|
|
34
|
-
* application that uses the ArkstackKitDriver.
|
|
35
|
-
*/
|
|
36
29
|
declare abstract class ArkstackKitContract<TApp, TMiddleware> {
|
|
37
30
|
abstract app: TApp;
|
|
38
31
|
abstract driver: ArkstackKitDriver<TApp, TMiddleware>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@arkstack/contract",
|
|
3
|
-
"version": "0.1
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Contract package for Arkstack providing contract-specific implementations of core Arkstack features such as routing, middleware, and database integration.",
|
|
6
6
|
"homepage": "https://arkstack.toneflix.net",
|
|
@@ -24,13 +24,11 @@
|
|
|
24
24
|
"access": "public"
|
|
25
25
|
},
|
|
26
26
|
"exports": {
|
|
27
|
-
".":
|
|
28
|
-
|
|
29
|
-
"import": "./dist/index.js"
|
|
30
|
-
}
|
|
27
|
+
".": "./dist/index.js",
|
|
28
|
+
"./package.json": "./package.json"
|
|
31
29
|
},
|
|
32
30
|
"scripts": {
|
|
33
|
-
"build": "tsdown",
|
|
31
|
+
"build": "tsdown --config-loader unrun",
|
|
34
32
|
"version:patch": "pnpm version patch"
|
|
35
33
|
}
|
|
36
34
|
}
|