refactor: website components (#8600)

This commit is contained in:
Noel
2022-09-06 19:48:33 +02:00
committed by GitHub
parent f3ce4a75d0
commit c3341570d9
55 changed files with 1910 additions and 2673 deletions

View File

@@ -0,0 +1,22 @@
export const PACKAGES = ['builders', 'collection', 'proxy', 'rest', 'voice', 'ws'];
export const DESCRIPTION =
"discord.js is a powerful node.js module that allows you to interact with the Discord API very easily. It takes a much more object-oriented approach than most other JS Discord libraries, making your bot's code significantly tidier and easier to comprehend.";
export const CODE_EXAMPLE = `import { Client, GatewayIntentBits } from 'discord.js';
const client = new Client({ intents: [GatewayIntentBits.Guilds] });
client.on('ready', () => {
console.log(\`Logged in as \${client.user.tag}!\`);
});
client.on('interactionCreate', async (interaction) => {
if (!interaction.isChatInputCommand()) return;
if (interaction.commandName === 'ping') {
await interaction.reply('Pong!');
}
});
await client.login('token');`;

View File

@@ -1 +0,0 @@
export const PACKAGES = ['builders', 'collection', 'proxy', 'rest', 'voice', 'ws'];

View File

@@ -1,6 +0,0 @@
import MiniSearch from 'minisearch';
export const miniSearch = new MiniSearch({
fields: ['name', 'summary'],
storeFields: ['name', 'summary', 'path'],
});