Skip to content

Commit

Permalink
chore(shared, typings): Add missing factory typings
Browse files Browse the repository at this point in the history
  • Loading branch information
xLuxy committed Sep 22, 2024
1 parent 6ebfa08 commit b795574
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
3 changes: 3 additions & 0 deletions types/client/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -576,6 +576,9 @@ declare module "@altv/client" {
static create(): HttpClient;

static getByID(id: number): HttpClient | null;

static setFactory(factory: typeof HttpClient): void;
static getFactory<T extends HttpClient>(): T;
}

export abstract class Object extends Entity {
Expand Down
2 changes: 1 addition & 1 deletion types/client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@altv/client",
"version": "0.0.46",
"version": "0.0.47",
"description": "This package contains the type definitions for the alt:V JS module v2 client types",
"types": "index.d.ts",
"files": [
Expand Down
3 changes: 3 additions & 0 deletions types/server/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1036,6 +1036,9 @@ declare module "@altv/server" {
// static readonly all: ReadonlyArray<ConnectionInfo>;

static getByID(id: number): ConnectionInfo | undefined;

static setFactory(factory: typeof ConnectionInfo): void;
static getFactory<T extends ConnectionInfo>(): T;
}

export namespace Events {
Expand Down
2 changes: 1 addition & 1 deletion types/server/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@altv/server",
"version": "0.0.47",
"version": "0.0.48",
"description": "This package contains the type definitions for the alt:V JS module v2 server types",
"types": "index.d.ts",
"files": [
Expand Down

0 comments on commit b795574

Please sign in to comment.