@squarecloud/utils
Advanced tools
Comparing version 1.0.1 to 1.0.2
import { Response } from "node-fetch"; | ||
export interface Status { | ||
interface StatusType { | ||
ram(): string; | ||
@@ -9,11 +9,11 @@ ramUsed(): string; | ||
export interface Terminal { | ||
info(message: unknown): void; | ||
warn(message: unknown): void; | ||
error(message: unknown): void; | ||
success(message: unknown): void; | ||
debug(message: unknown): void; | ||
interface TerminalType { | ||
info(message: any): void; | ||
warn(message: any): void; | ||
error(message: any): void; | ||
success(message: any): void; | ||
debug(message: any): void; | ||
} | ||
export interface Registry { | ||
interface RegistryType { | ||
/** | ||
@@ -40,16 +40,24 @@ * Conveniently saves information in a .log/.txt file. | ||
export function prototype(): void; | ||
declare module "@squarecloud/utils" { | ||
export const Status: StatusType; | ||
/** | ||
* It monitors a function and if an error is caught, it is stored / distributed. | ||
* @param fn Function to monitor. | ||
* @param path Error return. File or webhook. | ||
*/ | ||
export function apply(fn: Function, path: string): Promise<unknown | Response>; | ||
export const Terminal: TerminalType; | ||
/** | ||
* Send a Discord Webhook easily and conveniently. | ||
* @param object Webhook object or string. Example: { content: "hi content :)" }. | ||
* @param webhook Webhook URL. | ||
*/ | ||
export function webhook(object: string | object, webhook: string): Promise<Response>; | ||
export const Registry: RegistryType; | ||
export function prototype(): void; | ||
/** | ||
* It monitors a function and if an error is caught, it is stored / distributed. | ||
* @param fn Function to monitor. | ||
* @param path Error return. File or webhook. | ||
*/ | ||
export function apply(fn: Function, path: string): Promise<unknown | Response>; | ||
/** | ||
* Send a Discord Webhook easily and conveniently. | ||
* @param object Webhook object or string. Example: { content: "hi content :)" }. | ||
* @param webhook Webhook URL. | ||
*/ | ||
export function webhook(object: string | object, webhook: string): Promise<Response>; | ||
} |
{ | ||
"name": "@squarecloud/utils", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "Module designed to support Square Cloud activities.", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
18578
118