diff --git a/README.md b/README.md index 348f10eba..9f39ecaa5 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,13 @@ # Discordeno -> Discord API library for Deno +> Discord API library for [Deno](https://deno.land) [![Discord](https://img.shields.io/discord/785384884197392384?color=7289da&logo=discord&logoColor=dark)](https://discord.com/invite/5vBgXk3UcZ) ![Lint](https://github.com/discordeno/discordeno/workflows/Lint/badge.svg) ![Test](https://github.com/discordeno/discordeno/workflows/Test/badge.svg) +## Features + - **Secure & stable**: Discordeno is comparatively more stable than the other libraries. One of the greatest issues with almost every library is stability; types are outdated, less (or minimal) parity with the API, core maintainers @@ -14,34 +16,20 @@ convenience. Discordeno internally checks all missing permissions before forwarding a request to the API so that the client does not get globally-banned by Discord. -- **Efficient & lightweight**: Discordeno is simplistic and easy-to-use. Always - prefer defaults that Discord recommends or the best configuration for the - majority―if necessary, it is remarkably customizable, versatile, and - efficient. -- **Functional API**: This will produce a cleaner and more performant code while - removing the difficulties of extending built-in classes and inheritance. Avoid - potential memory leaks or crashes because of too many listeners or other silly - issues. +- **Efficient & lightweight**: Discordeno is simplistic, easy-to-use, versatile, + and efficient. Uses + [Convention Over Configuration](https://en.wikipedia.org/wiki/Convention_over_configuration) + design paradigm ― prefers defaults that Discord recommends or the best + configuration for the majority of the users. +- [**Functional API**](https://en.wikipedia.org/wiki/Functional_programming): + This will produce an overall concise and more performant code while removing + the difficulties of extending built-in classes and inheritance. -## Usage +## Getting Started -### Beginner Developers +### Minimal Example -Don't worry a lot of developers start out coding their first projects as a -Discord bot (I did 😉) and it is not so easy to do so. Discordeno is built -considering all the issues with pre-existing libraries and issues that I had -when I first started out coding bots. If you are a beginner developer, you may -check out these awesome official and unofficial boilerplates: - -- Official Discordeno Boilerplate - - [GitHub](https://github.com/Skillz4Killz/Discordeno-bot-template) - - [Features](https://github.com/Skillz4Killz/Discordeno-bot-template#features) - -If you do not wish to use a boilerplate, you may continue reading. - -### Advanced Developers - -Here's a minimal example to get started with: +Here is a minimal example to get started with: ```typescript import { startBot } from "https://deno.land/x/discordeno/mod.ts"; @@ -62,6 +50,18 @@ startBot({ }); ``` +### Boilerplates + +Note to developers: don't worry a lot of developers start out programming a +Discord bot as their first project (I did 😉) and it is not so easy to do so. +Discordeno is built considering all the issues that I and a lot of developers +that I personally know had when I first started out coding Discord bots with +existing libraries. If you are a beginner, you can check out these awesome +official and unofficial boilerplates: + +- [Discordeno Bot Template (official)](https://github.com/Skillz4Killz/Discordeno-bot-template) +- [Add Your Own!](https://github.com/discordeno/discordeno/pulls) + ## Useful Links - [Website](https://discordeno.mod.land) @@ -70,9 +70,7 @@ startBot({ ## Contributing -We appreciate your help! - -Before contributing, please read the +We appreciate your help! Before contributing, please read the [Contributing Guide](https://github.com/discordeno/discordeno/blob/master/.github/CONTRIBUTING.md). ### License diff --git a/docs/src/README.md b/docs/src/README.md index 97eeaffd0..8d8683087 100644 --- a/docs/src/README.md +++ b/docs/src/README.md @@ -1,11 +1,13 @@ # Discordeno -> Discord API library for Deno +> Discord API library for [Deno](https://deno.land) [![Discord](https://img.shields.io/discord/785384884197392384?color=7289da&logo=discord&logoColor=dark)](https://discord.com/invite/5vBgXk3UcZ) ![Lint](https://github.com/discordeno/discordeno/workflows/Lint/badge.svg) ![Test](https://github.com/discordeno/discordeno/workflows/Test/badge.svg) +## Features + - **Secure & stable**: Discordeno is comparatively more stable than the other libraries. One of the greatest issues with almost every library is stability; types are outdated, less (or minimal) parity with the API, core maintainers @@ -14,14 +16,14 @@ convenience. Discordeno internally checks all missing permissions before forwarding a request to the API so that the client does not get globally-banned by Discord. -- **Efficient & lightweight**: Discordeno is simplistic and easy-to-use. Always - prefer defaults that Discord recommends or the best configuration for the - majority―if necessary, it is remarkably customizable, versatile, and - efficient. -- **Functional API**: This will produce a cleaner and more performant code while - removing the difficulties of extending built-in classes and inheritance. Avoid - potential memory leaks or crashes because of too many listeners or other silly - issues. +- **Efficient & lightweight**: Discordeno is simplistic, easy-to-use, versatile, + and efficient. Uses + [Convention Over Configuration](https://en.wikipedia.org/wiki/Convention_over_configuration) + design paradigm ― prefers defaults that Discord recommends or the best + configuration for the majority of the users. +- [**Functional API**](https://en.wikipedia.org/wiki/Functional_programming): + This will produce an overall concise and more performant code while removing + the difficulties of extending built-in classes and inheritance. ## Useful Links diff --git a/docs/src/gettingstarted.md b/docs/src/gettingstarted.md index 6ea2a3754..ae37cb335 100644 --- a/docs/src/gettingstarted.md +++ b/docs/src/gettingstarted.md @@ -2,19 +2,8 @@ Discordeno aims for a simple, easy and stress-free interaction with the Discord API. Always supporting the latest version to ensure stability, consistency and -the best developer experience. - -This website serves as the purpose for introducing Discordeno to developers. The -full documentation for all the functions and methods can be visited by clicking -the link below: - -[View Documentation on Deno](https://doc.deno.land/https/deno.land/x/discordeno/mod.ts) - -## Useful Links - -- [GitHub Repository](https://github.com/discordeno/discordeno) -- [Deno Page](https://deno.land/x/discordeno) -- [Website](https://discordeno.mod.land) +the best developer experience. This guide serves as the purpose for introducing +Discordeno to developers. ## Requirements @@ -56,22 +45,18 @@ Starting with Discordeno is very simple, you can start from scratch without any boilerplates/frameworks: Add this snippet of code into a new TypeScript file: ```ts -import { - Intents, - startBot, -} from "https://deno.land/x/discordeno@10.0.0/mod.ts"; -import config from "./config.ts"; +import { startBot } from "https://deno.land/x/discordeno/mod.ts"; startBot({ - token: config.token, - intents: [Intents.GUILD_MESSAGES, Intents.GUILDS], + token: "BOT TOKEN", + intents: ["GUILDS", "GUILD_MESSAGES"], eventHandlers: { - ready: () => { - console.log(`Logged!`); + ready() { + console.log("Successfully connected to gateway"); }, - messageCreate: (message) => { + messageCreate(message) { if (message.content === "!ping") { - message.reply("Pong"); + message.reply("Pong using Discordeno!"); } }, }, diff --git a/docs/src/djs.md b/docs/src/migrating.md similarity index 97% rename from docs/src/djs.md rename to docs/src/migrating.md index a5f1ef28d..14f29ae24 100644 --- a/docs/src/djs.md +++ b/docs/src/migrating.md @@ -1,11 +1,10 @@ -# Discord.js to Discordeno Guide +# Migrating -## Understanding The Goals of This Guide +# Migrating from Discord.js -This guide is not intended to trash or hate on Discord.JS. In fact, Discord.JS -is the most popular Node.JS library which is why most users wanting to use -Discordeno come from Discord.JS. Today, I had a user ask me for a guide to -convert a Discord.JS bot to Discordeno. That was the start of this guide. +This migration guide is not intended to discredit Discord.js authors/maintainers +or Discord.js itself. In fact, Discord.js is the most popular Node.js library, +admired and praised by a lot of JavaScript developers. ## Finding A Open Source Bot