Merge pull request #1966 from lts20050703/gh-1963

README: Fileloader Plugin: no longer need to check for the compatible discordeno version
This commit is contained in:
Skillz4Killz
2022-02-01 12:03:26 -05:00
committed by GitHub
+14 -14
View File
@@ -1,26 +1,26 @@
# fileloader-plugin
> Please check `./deps.ts` for the compatible `discordeno` version!
This plugin leverages the ability to write files, and then import them.
## Code Example
```typescript
import { createBot, enableFileLoaderPlugin, startBot } from './deps.ts' // Import discordeno and this plugin.
import { createBot, enableFileLoaderPlugin, startBot } from "./deps.ts"; // Import discordeno and this plugin.
console.log('Starting Up the Bot, this might take awhile...');
console.log("Starting Up the Bot, this might take awhile...");
const bot = enableFileLoaderPlugin(createBot({
token: '', // Your bot's token
botId: 0n, // Your bot's "Application Id",
intents: [],
events: {
ready() {
console.log('Bot Ready');
}
}
}));
const bot = enableFileLoaderPlugin(
createBot({
token: "", // Your bot's token
botId: 0n, // Your bot's "Application Id",
intents: [],
events: {
ready() {
console.log("Bot Ready");
},
},
})
);
bot.fastFileLoader([
// './src/commands', etc. This works just like `import [something] from [somewhere]`