@raclettejs/types 0.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/dependencies.d.ts +4 -0
- package/dist/dependencies.js +1 -0
- package/dist/dependencies.ts +4 -0
- package/dist/fastify.d.ts +26 -0
- package/dist/fastify.js +1 -0
- package/dist/fastify.ts +28 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +4 -0
- package/dist/index.ts +2 -0
- package/package.json +29 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import "fastify";
|
|
2
|
+
import { MongooseConnection, SocketIO } from "./dependencies";
|
|
3
|
+
import { preHandlerHookHandler } from "fastify";
|
|
4
|
+
declare module "fastify" {
|
|
5
|
+
interface FastifyInstance {
|
|
6
|
+
db: MongooseConnection;
|
|
7
|
+
authenticate: preHandlerHookHandler;
|
|
8
|
+
wss: SocketIO;
|
|
9
|
+
eventbus: any;
|
|
10
|
+
redis: any;
|
|
11
|
+
http: any;
|
|
12
|
+
taskManager: any;
|
|
13
|
+
}
|
|
14
|
+
interface FastifyRequest {
|
|
15
|
+
db: MongooseConnection;
|
|
16
|
+
user: any;
|
|
17
|
+
requestParams: any;
|
|
18
|
+
}
|
|
19
|
+
interface RouteOptions {
|
|
20
|
+
skipHeaderValidation?: boolean;
|
|
21
|
+
}
|
|
22
|
+
interface FastifyContextConfig {
|
|
23
|
+
type?: string;
|
|
24
|
+
broadcast?: string[] | boolean;
|
|
25
|
+
}
|
|
26
|
+
}
|
package/dist/fastify.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "fastify";
|
package/dist/fastify.ts
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import "fastify";
|
|
2
|
+
import { MongooseConnection, SocketIO } from "./dependencies";
|
|
3
|
+
import type { RedisService, HttpService, TaskManager, ClientPayloadRequestData, User } from "@raclettejs/raclette-core";
|
|
4
|
+
import { FastifyReply } from "fastify";
|
|
5
|
+
declare module "fastify" {
|
|
6
|
+
interface FastifyInstance {
|
|
7
|
+
db: MongooseConnection;
|
|
8
|
+
authenticate: (req: FastifyRequest, res: FastifyReply) => Promise<void>;
|
|
9
|
+
wss: SocketIO;
|
|
10
|
+
eventbus: any;
|
|
11
|
+
redis: RedisService;
|
|
12
|
+
http: HttpService;
|
|
13
|
+
taskManager: TaskManager;
|
|
14
|
+
}
|
|
15
|
+
interface FastifyRequest {
|
|
16
|
+
db: MongooseConnection;
|
|
17
|
+
user: User;
|
|
18
|
+
requestParams: ClientPayloadRequestData;
|
|
19
|
+
}
|
|
20
|
+
interface RouteOptions {
|
|
21
|
+
skipHeaderValidation?: boolean;
|
|
22
|
+
}
|
|
23
|
+
interface FastifyContextConfig {
|
|
24
|
+
type?: string;
|
|
25
|
+
broadcast?: string[] | boolean;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
export {};
|
package/dist/index.d.ts
ADDED
package/dist/index.js
ADDED
package/dist/index.ts
ADDED
package/package.json
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@raclettejs/types",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "Type definitions for the raclette framework",
|
|
5
|
+
"types": "dist/index.d.ts",
|
|
6
|
+
"repository": "https://gitlab.com/raclettejs/types",
|
|
7
|
+
"author": "Pacifico Digital Explorations GmbH <info@raclettejs.com>",
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"scripts": {
|
|
10
|
+
"build": "tsc || true",
|
|
11
|
+
"prepublishOnly": "yarn build"
|
|
12
|
+
},
|
|
13
|
+
"files": [
|
|
14
|
+
"dist"
|
|
15
|
+
],
|
|
16
|
+
"dependencies": {
|
|
17
|
+
"@types/node": "*",
|
|
18
|
+
"fastify": "^5.4",
|
|
19
|
+
"mongoose": "^8.16.3",
|
|
20
|
+
"socket.io": "^4.7.5",
|
|
21
|
+
"typescript": "^5.8.3"
|
|
22
|
+
},
|
|
23
|
+
"peerDependencies": {
|
|
24
|
+
"@raclettejs/core": "*"
|
|
25
|
+
},
|
|
26
|
+
"devDependencies": {
|
|
27
|
+
"@raclettejs/core": "^0.0.1"
|
|
28
|
+
}
|
|
29
|
+
}
|