Skip to content

Commit

Permalink
What if...?
Browse files Browse the repository at this point in the history
  • Loading branch information
Secreto31126 committed Jan 2, 2025
1 parent 5da46eb commit 59fc38d
Show file tree
Hide file tree
Showing 17 changed files with 23 additions and 23 deletions.
6 changes: 3 additions & 3 deletions src/emitters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import type {
ServerPricing,
ServerError,
PostData
} from "./types";
import type { WhatsAppAPI } from "./index";
import type { MaybePromise } from "./utils";
} from "./types.d.ts";
import type { WhatsAppAPI } from "./index.d.ts";
import type { MaybePromise } from "./utils.d.ts";

/**
* Callback for "sent" event
Expand Down
2 changes: 1 addition & 1 deletion src/errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

// This import makes the docs' links work
// eslint-disable-next-line @typescript-eslint/no-unused-vars
import type { WhatsAppAPI } from "./index";
import type { WhatsAppAPI } from "./index.d.ts";

/**
* The library's base exception class.
Expand Down
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import type {
OnSentArgs,
OnStatus,
OnStatusArgs
} from "./emitters";
} from "./emitters.d.ts";

import { escapeUnicode, MaybePromise } from "./utils.js";
import { DEFAULT_API_VERSION } from "./types.js";
Expand Down
2 changes: 1 addition & 1 deletion src/messages/contacts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {
ContactUniqueComponent,
ContactMultipleComponent
} from "../types.js";
import type { AtLeastOne } from "../utils";
import type { AtLeastOne } from "../utils.d.ts";

/**
* @group Contacts
Expand Down
2 changes: 1 addition & 1 deletion src/messages/globals.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Section, type ClientTypedMessageComponent } from "../types.js";
import type { AtLeastOne } from "../utils";
import type { AtLeastOne } from "../utils.d.ts";

/**
* TS knowledge intensifies
Expand Down
4 changes: 2 additions & 2 deletions src/messages/interactive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import {
Section,
type InteractiveAction
} from "../types.js";
import type { AtLeastOne } from "../utils";
import type { AtLeastOne } from "../utils.d.ts";

import type { Document, Image, Video } from "./media";
import type { Document, Image, Video } from "./media.d.ts";

import { CatalogProduct, Product, ProductSection } from "./globals.js";

Expand Down
6 changes: 3 additions & 3 deletions src/messages/template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ import {
type ClientTypedMessageComponent,
type TemplateComponent
} from "../types.js";
import type { AtLeastOne, XOR } from "../utils";
import type { AtLeastOne, XOR } from "../utils.d.ts";

import type { Location } from "./location";
import type { Document, Image, Video } from "./media";
import type { Location } from "./location.d.ts";
import type { Document, Image, Video } from "./media.d.ts";

import { CatalogProduct, Product, ProductSection } from "./globals.js";

Expand Down
2 changes: 1 addition & 1 deletion src/middleware/adonis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { WhatsAppAPIMiddleware } from "./globals.js";
import { WhatsAppAPIError } from "../errors.js";

import type { Request } from "@adonisjs/http-server";
import type { GetParams, PostData } from "../types";
import type { GetParams, PostData } from "../types.d.ts";

/**
* AdonisJS middleware for WhatsAppAPI
Expand Down
2 changes: 1 addition & 1 deletion src/middleware/express.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { WhatsAppAPIMiddleware } from "./globals.js";
import { WhatsAppAPIError } from "../errors.js";

import type { Request } from "express";
import type { GetParams } from "../types";
import type { GetParams } from "../types.d.ts";

/**
* Express.js middleware for WhatsAppAPI
Expand Down
2 changes: 1 addition & 1 deletion src/middleware/node-http.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { WhatsAppAPIError } from "../errors.js";
import type { IncomingMessage } from "node:http";
import type { Readable } from "node:stream";

import type { GetParams } from "../types";
import type { GetParams } from "../types.d.ts";

/**
* node:http server middleware for WhatsAppAPI
Expand Down
2 changes: 1 addition & 1 deletion src/middleware/vercel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { WhatsAppAPI as NodeHTTPMiddleware } from "./node-http.js";
import { WhatsAppAPIError } from "../errors.js";

import type { VercelRequest } from "@vercel/node";
import type { GetParams } from "../types.js";
import type { GetParams } from "../types.d.ts";

/**
* Vercel serverless functions middleware for WhatsAppAPI (Node/Next.js)
Expand Down
2 changes: 1 addition & 1 deletion src/middleware/web-standard.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { WhatsAppAPIMiddleware } from "./globals.js";
import { WhatsAppAPIError } from "../errors.js";

import type { GetParams } from "../types";
import type { GetParams } from "../types.d.ts";

/**
* Web Standard API http server middleware for WhatsAppAPI (deno/bun/SvelteKit/NextJS/Hono)
Expand Down
2 changes: 1 addition & 1 deletion src/setup/bun.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { WhatsAppAPIConstructorArguments } from "../types";
import type { WhatsAppAPIConstructorArguments } from "../types.d.ts";

/**
* A Bun quick setup for the WhatsAppAPI
Expand Down
2 changes: 1 addition & 1 deletion src/setup/deno.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { WhatsAppAPIConstructorArguments } from "../types";
import type { WhatsAppAPIConstructorArguments } from "../types.d.ts";

/**
* A Deno quick setup for the WhatsAppAPI
Expand Down
2 changes: 1 addition & 1 deletion src/setup/node.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { WhatsAppAPIConstructorArguments } from "../types";
import type { WhatsAppAPIConstructorArguments } from "../types.d.ts";

// If this line of code didn't exist,
// setup would be a single file rather than a folder
Expand Down
2 changes: 1 addition & 1 deletion src/setup/web.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { WhatsAppAPIConstructorArguments } from "../types";
import type { WhatsAppAPIConstructorArguments } from "../types.d.ts";

/**
* A Web quick setup for the WhatsAppAPI
Expand Down
4 changes: 2 additions & 2 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import type {
Template,
Reaction,
Contacts
} from "./messages";
import type { AtLeastOne } from "./utils";
} from "./messages/index.d.ts";
import type { AtLeastOne } from "./utils.d.ts";

export const DEFAULT_API_VERSION = "v21.0";

Expand Down

0 comments on commit 59fc38d

Please sign in to comment.