diff --git a/.gitignore b/.gitignore index f3ec34a..1c5dc4f 100644 --- a/.gitignore +++ b/.gitignore @@ -11,4 +11,5 @@ npm/ # Examples node_modules/ package-lock.json -package.json \ No newline at end of file +package.json +bun.lockb \ No newline at end of file diff --git a/egg.json b/egg.json index 34ad530..2918bb3 100644 --- a/egg.json +++ b/egg.json @@ -1,27 +1,27 @@ { - "$schema": "https://x.nest.land/eggs@0.3.10/src/schema.json", - "name": "biscuit", - "entry": "./mod.ts", - "description": "A brand new bleeding edge non bloated Discord library", - "homepage": "https://github.com/oasisjs/biscuit", - "version": "0.1.0", - "releaseType": "minor", - "unstable": false, - "unlisted": false, - "files": [ - "./packages/**/*", - "./mod.ts", - "LICENSE", - "README.md" - ], - "ignore": [ - "npm", - "build.ts", - "scripts.ts", - ".git" - ], - "checkFormat": true, - "checkTests": false, - "checkInstallation": false, - "check": true + "$schema": "https://x.nest.land/eggs@0.3.10/src/schema.json", + "name": "biscuit", + "entry": "./mod.ts", + "description": "A brand new bleeding edge non bloated Discord library", + "homepage": "https://github.com/oasisjs/biscuit", + "version": "0.1.0", + "releaseType": "minor", + "unstable": false, + "unlisted": false, + "files": [ + "./packages/**/*", + "./mod.ts", + "LICENSE", + "README.md" + ], + "ignore": [ + "npm", + "build.ts", + "scripts.ts", + ".git" + ], + "checkFormat": true, + "checkTests": false, + "checkInstallation": false, + "check": true } diff --git a/examples/bun.js b/examples/bun.js index 29ee019..833120c 100644 --- a/examples/bun.js +++ b/examples/bun.js @@ -1,5 +1,8 @@ -// TODO: remove and include the library appropriately -import { GatewayIntents, Session } from "./deps.ts"; +/** + * Bun example + */ + +import { GatewayIntents, Session } from "@oasisjs/biscuit"; const token = process.env.TOKEN; const intents = GatewayIntents.MessageContent | GatewayIntents.Guilds | GatewayIntents.GuildMessages; diff --git a/examples/deno.ts b/examples/deno.ts index a840ce8..78ae82e 100644 --- a/examples/deno.ts +++ b/examples/deno.ts @@ -1,6 +1,6 @@ /** * Deno example -*/ + */ import "https://deno.land/std@0.146.0/dotenv/load.ts"; import { GatewayIntents, Session } from "https://x.nest.land/biscuit@0.1.0/mod.ts"; diff --git a/examples/deps.ts b/examples/deps.ts deleted file mode 100644 index 54ecd20..0000000 --- a/examples/deps.ts +++ /dev/null @@ -1,2 +0,0 @@ -// TODO: remove and include the library appropriately -export * from "../mod.ts"; diff --git a/packages/biscuit/structures/ThreadMember.ts b/packages/biscuit/structures/ThreadMember.ts index 416f21e..bc4c194 100644 --- a/packages/biscuit/structures/ThreadMember.ts +++ b/packages/biscuit/structures/ThreadMember.ts @@ -7,7 +7,7 @@ import * as Routes from "../Routes.ts"; /** * A member that comes from a thread * @link https://discord.com/developers/docs/resources/channel#thread-member-object - * **/ + * * */ export class ThreadMember implements Model { constructor(session: Session, data: DiscordThreadMember) { this.session = session; diff --git a/packages/biscuit/structures/guilds.ts b/packages/biscuit/structures/guilds.ts index eb5350b..84a4b6a 100644 --- a/packages/biscuit/structures/guilds.ts +++ b/packages/biscuit/structures/guilds.ts @@ -691,9 +691,8 @@ export class Guild extends BaseGuild implements Model { splash: "splashURL" in options ? options.splashURL || urlToBase64(options.splashURL!) : options.splashHash || Util.iconBigintToHash(options.iconHash!), - banner: "bannerURL" in options - ? options.bannerURL || urlToBase64(options.bannerURL!) - : options.bannerHash || Util.iconBigintToHash(options.bannerHash!), + banner: "bannerURL" in options ? options.bannerURL || urlToBase64(options.bannerURL!) + : options.bannerHash || Util.iconBigintToHash(options.bannerHash!), discovery_splash: "discoverySplashURL" in options ? options.discoverySplashURL || urlToBase64(options.discoverySplashURL!) : options.discoverySplashHash || Util.iconBigintToHash(options.discoverySplashHash!), diff --git a/packages/discordeno/types/shared.ts b/packages/discordeno/types/shared.ts index b3c189a..8d86e7a 100644 --- a/packages/discordeno/types/shared.ts +++ b/packages/discordeno/types/shared.ts @@ -1237,7 +1237,7 @@ export type CamelCase = S extends `${infer P1}_${infer P2}${in : Lowercase; export type Camelize = { [K in keyof T as CamelCase]: T[K] extends Array ? U extends {} ? Array> - : T[K] + : T[K] : T[K] extends {} ? Camelize : never; };