refactor: change backend to typescript and update types and variables accordingly
This commit is contained in:
Vendored
+11
@@ -0,0 +1,11 @@
|
||||
import type {AuthTokenPayload} from "../services/tokenService.js";
|
||||
|
||||
declare global {
|
||||
namespace Express {
|
||||
interface Request {
|
||||
user?: AuthTokenPayload;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export {};
|
||||
@@ -0,0 +1,8 @@
|
||||
export type ErrorCode = readonly [code: string, message: string];
|
||||
|
||||
export interface Response {
|
||||
success: boolean;
|
||||
code: string;
|
||||
data: any;
|
||||
message: string;
|
||||
}
|
||||
Reference in New Issue
Block a user