mirror of
https://github.com/sern-handler/website
synced 2026-06-06 09:26:46 +00:00
Compare commits
1 Commits
feat/plugi
...
feat/versi
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
61e566eb6d |
6
.github/workflows/docusaurus.yml
vendored
6
.github/workflows/docusaurus.yml
vendored
@@ -15,12 +15,12 @@ jobs:
|
||||
- uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 18
|
||||
cache: yarn
|
||||
cache: npm
|
||||
|
||||
- name: Install dependencies
|
||||
run: yarn install --immutable
|
||||
run: npm ci
|
||||
- name: Build website
|
||||
run: yarn build
|
||||
run: npm run build
|
||||
|
||||
# Popular action to deploy to GitHub Pages:
|
||||
# Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus
|
||||
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -14,7 +14,7 @@
|
||||
.env.development.local
|
||||
.env.test.local
|
||||
.env.production.local
|
||||
.yarn/install-state.gz
|
||||
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
131
.idea/workspace.xml
generated
131
.idea/workspace.xml
generated
@@ -4,8 +4,56 @@
|
||||
<option name="autoReloadType" value="SELECTIVE" />
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="53dd69d3-e01a-4656-b414-c727f5aa549a" name="Changes" comment="limit description characters to 100">
|
||||
<change beforePath="$PROJECT_DIR$/src/pages/index.module.css" beforeDir="false" afterPath="$PROJECT_DIR$/src/pages/index.module.css" afterDir="false" />
|
||||
<list default="true" id="53dd69d3-e01a-4656-b414-c727f5aa549a" name="Changes" comment="docs: add new plugins docs">
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/CommandExecutable.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/CommandExecutable.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/Context.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/Context.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/DefaultErrorHandling.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/DefaultErrorHandling.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/DefaultLogging.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/DefaultLogging.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/DefaultModuleManager.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/DefaultModuleManager.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/EventExecutable.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/EventExecutable.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/ModuleStore.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/ModuleStore.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/classes/SernEmitter.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/classes/SernEmitter.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/enums/CommandType.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/enums/CommandType.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/enums/EventType.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/enums/EventType.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/enums/PayloadType.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/enums/PayloadType.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/enums/PluginType.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/enums/PluginType.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/enums/SernError.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/enums/SernError.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/AutocompleteCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/AutocompleteCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/BothCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/BothCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ButtonCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ButtonCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ChannelSelectCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ChannelSelectCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/CommandPlugin.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/CommandPlugin.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ContextMenuMsg.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ContextMenuMsg.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ContextMenuUser.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ContextMenuUser.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ControlPlugin.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ControlPlugin.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/Controller.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/Controller.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/Dependencies.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/Dependencies.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/DependencyConfiguration.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/DependencyConfiguration.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/DiscordEventCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/DiscordEventCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ErrorHandling.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ErrorHandling.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/EventPlugin.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/EventPlugin.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ExternalEventCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ExternalEventCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/InitArgs.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/InitArgs.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/InitPlugin.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/InitPlugin.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/Logging.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/Logging.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/MentionableSelectCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/MentionableSelectCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ModalSubmitCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ModalSubmitCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/Module.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/Module.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/ModuleManager.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/ModuleManager.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/Plugin.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/Plugin.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/RoleSelectCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/RoleSelectCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/SernAutocompleteData.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/SernAutocompleteData.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/SernEventCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/SernEventCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/SernSubCommandData.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/SernSubCommandData.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/SernSubCommandGroupData.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/SernSubCommandGroupData.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/SlashCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/SlashCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/StringSelectCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/StringSelectCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/TextCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/TextCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/UserSelectCommand.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/UserSelectCommand.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/interfaces/Wrapper.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/interfaces/Wrapper.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/modules.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/modules.md" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/docs/api/namespaces/Sern.md" beforeDir="false" afterPath="$PROJECT_DIR$/docs/api/namespaces/Sern.md" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
@@ -43,35 +91,26 @@
|
||||
<component name="MarkdownSettingsMigration">
|
||||
<option name="stateVersion" value="1" />
|
||||
</component>
|
||||
<component name="ProjectColorInfo">{
|
||||
"associatedIndex": 5
|
||||
}</component>
|
||||
<component name="ProjectId" id="2DJXFY4dwukGLOzXi05b6lHCkuk" />
|
||||
<component name="ProjectViewState">
|
||||
<option name="hideEmptyMiddlePackages" value="true" />
|
||||
<option name="showLibraryContents" value="true" />
|
||||
</component>
|
||||
<component name="PropertiesComponent"><![CDATA[{
|
||||
"keyToString": {
|
||||
"ASKED_SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
||||
"Git.Branch.Popup.ShowAllRemotes": "true",
|
||||
"RunOnceActivity.OpenProjectViewOnStart": "true",
|
||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||
"WebServerToolWindowFactoryState": "false",
|
||||
"git-widget-placeholder": "feat/pluginPage",
|
||||
"kotlin-language-version-configured": "true",
|
||||
"last_opened_file_path": "C:/Users/jacob/OneDrive/Desktop/Projects/sern/website",
|
||||
"node.js.detected.package.eslint": "true",
|
||||
"node.js.selected.package.eslint": "(autodetect)",
|
||||
"node.js.selected.package.tslint": "(autodetect)",
|
||||
"nodejs_package_manager_path": "npm",
|
||||
"project.structure.last.edited": "Modules",
|
||||
"project.structure.proportion": "0.0",
|
||||
"project.structure.side.proportion": "0.0",
|
||||
"ts.external.directory.path": "/home/srizan/Documents/Development/sern-website/node_modules/typescript/lib",
|
||||
"vue.rearranger.settings.migration": "true"
|
||||
<component name="PropertiesComponent">{
|
||||
"keyToString": {
|
||||
"ASKED_SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
||||
"Git.Branch.Popup.ShowAllRemotes": "true",
|
||||
"RunOnceActivity.OpenProjectViewOnStart": "true",
|
||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||
"WebServerToolWindowFactoryState": "false",
|
||||
"last_opened_file_path": "C:/Users/jacob/OneDrive/Desktop/Projects/sern/website",
|
||||
"nodejs_package_manager_path": "npm",
|
||||
"project.structure.last.edited": "Modules",
|
||||
"project.structure.proportion": "0.0",
|
||||
"project.structure.side.proportion": "0.0",
|
||||
"ts.external.directory.path": "E:\\IntelliJ IDEA 2022.1.1\\plugins\\JavaScriptLanguage\\jsLanguageServicesImpl\\external"
|
||||
}
|
||||
}]]></component>
|
||||
}</component>
|
||||
<component name="RecentsManager">
|
||||
<key name="MoveFile.RECENT_KEYS">
|
||||
<recent name="C:\Users\jacob\IdeaProjects\website\static\img" />
|
||||
@@ -143,8 +182,6 @@
|
||||
<workItem from="1671119393024" duration="3889000" />
|
||||
<workItem from="1673974979200" duration="2385000" />
|
||||
<workItem from="1674757791435" duration="925000" />
|
||||
<workItem from="1713448008567" duration="8323000" />
|
||||
<workItem from="1714235989637" duration="2619000" />
|
||||
</task>
|
||||
<task id="LOCAL-00001" summary="feat: remove old index.html in static/">
|
||||
<created>1660418841831</created>
|
||||
@@ -335,31 +372,7 @@
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1673976828238</updated>
|
||||
</task>
|
||||
<task id="LOCAL-00028" summary="initial built from the ground up page done">
|
||||
<option name="closed" value="true" />
|
||||
<created>1713463473768</created>
|
||||
<option name="number" value="00028" />
|
||||
<option name="presentableId" value="LOCAL-00028" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1713463473768</updated>
|
||||
</task>
|
||||
<task id="LOCAL-00029" summary="copilot leak">
|
||||
<option name="closed" value="true" />
|
||||
<created>1714242192383</created>
|
||||
<option name="number" value="00029" />
|
||||
<option name="presentableId" value="LOCAL-00029" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1714242192383</updated>
|
||||
</task>
|
||||
<task id="LOCAL-00030" summary="limit description characters to 100">
|
||||
<option name="closed" value="true" />
|
||||
<created>1714243202496</created>
|
||||
<option name="number" value="00030" />
|
||||
<option name="presentableId" value="LOCAL-00030" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1714243202496</updated>
|
||||
</task>
|
||||
<option name="localTasksCounter" value="31" />
|
||||
<option name="localTasksCounter" value="28" />
|
||||
<servers />
|
||||
</component>
|
||||
<component name="TypeScriptGeneratedFilesManager">
|
||||
@@ -377,6 +390,10 @@
|
||||
</option>
|
||||
</component>
|
||||
<component name="VcsManagerConfiguration">
|
||||
<MESSAGE value="feat: remove old index.html in static/" />
|
||||
<MESSAGE value="feat: edit action" />
|
||||
<MESSAGE value="feat: delete needless assets/dir" />
|
||||
<MESSAGE value="feat: action changes and edit link" />
|
||||
<MESSAGE value="feat: add favicon" />
|
||||
<MESSAGE value="fix: broken link" />
|
||||
<MESSAGE value="chore: edit link so no new windows" />
|
||||
@@ -398,14 +415,6 @@
|
||||
<MESSAGE value="feat: update documentation and clarify documentation" />
|
||||
<MESSAGE value="fix: links" />
|
||||
<MESSAGE value="docs: add new plugins docs" />
|
||||
<MESSAGE value="initial built from the ground up page done" />
|
||||
<MESSAGE value="wow such feature" />
|
||||
<MESSAGE value="copilot leak" />
|
||||
<MESSAGE value="limit description characters to 100" />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="limit description characters to 100" />
|
||||
</component>
|
||||
<component name="XSLT-Support.FileAssociations.UIState">
|
||||
<expand />
|
||||
<select />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="docs: add new plugins docs" />
|
||||
</component>
|
||||
</project>
|
||||
@@ -1 +0,0 @@
|
||||
nodeLinker: node-modules
|
||||
2
404.html
2
404.html
@@ -20,7 +20,7 @@
|
||||
<h1 style="margin:0; font-size:150px; line-height:150px; font-weight:bold;">404</h1>
|
||||
<h2 style="margin-top:20px;font-size: 30px;">Not Found
|
||||
</h2>
|
||||
<p>The link you visited may be broken or invalid.</p>
|
||||
<p>The link you visited is may be broken or invalid.</p>
|
||||
<div class="button">
|
||||
<h2>
|
||||
<a href="http://sern-handler.js.org" title="Back to home" style="color: #444;">Back to homepage</a>
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
---
|
||||
slug: railway-deploy
|
||||
title: Deploying sern with Railway
|
||||
authors: [Duro]
|
||||
tags: [guides]
|
||||
---
|
||||
|
||||
In this guide, I'll be showing you how to deploy your sern bot with [Railway](https://railway.app/).
|
||||
|
||||
This guide assumes you have a sern bot already set up and ready to deploy. If you don't, you can follow the [Getting Started](/blog/getting-started) guide to set up your bot.
|
||||
|
||||
## GitHub Repository
|
||||
|
||||
The first thing you'll need to deploy your bot is a GitHub repository for your bot. If you don't have one, you can create one by following the [GitHub guide](https://docs.github.com/en/get-started/quickstart/create-a-repo).
|
||||
|
||||
Once you have your repository set up, you can push your bot's code to the repository, and you're ready to deploy using Railway.
|
||||
|
||||
## Railway Setup
|
||||
|
||||
After you have your bot's code in a GitHub repository, you'll need to create an account on Railway. You can sign up using your GitHub account at [railway.app](https://railway.app/).
|
||||
|
||||
Once you've created your account, navigate to the [dashboard](https://railway.app/dashboard) and click the "New Project" button. Click the "Deploy from GitHub repo" button, and select your bot's repository.
|
||||
|
||||
Once you've selected your repository, click the "Add Variables" button to add your bot's environment variables. You'll need your environment variables from your `.env` file to add to Railway. (You can also add these later if you want.)
|
||||
|
||||
## Deploy
|
||||
|
||||
Once you've added your environment variables, click the "Deploy" button, and Railway will start deploying your bot. Once the deployment is complete, you'll be able to see your bot's URL and logs.
|
||||
|
||||
:::note
|
||||
Make sure you add your environment variables, and your node start script is correct in your `package.json` file.
|
||||
|
||||
If you have any issues deploying your bot, you can check the logs for any errors.
|
||||
:::
|
||||
|
||||
That's it! Your bot is now deployed and running on Railway. If you have any issues or questions, feel free to ask in the [sern Discord server](https://sern.dev/discord).
|
||||
@@ -17,8 +17,3 @@ Murtatrxx:
|
||||
title: Developer
|
||||
url: https://github.com/Murtatrxx
|
||||
image_url: https://github.com/Murtatrxx.png
|
||||
Duro:
|
||||
name: Duro
|
||||
title: Developer
|
||||
url: https://github.com/DuroCodes
|
||||
image_url: https://github.com/DuroCodes.png
|
||||
|
||||
@@ -1,206 +0,0 @@
|
||||
// @ts-check
|
||||
// Note: type annotations allow type checking and IDEs autocompletion
|
||||
|
||||
const lightCodeTheme = require('prism-react-renderer').themes.nightOwlLight;
|
||||
const darkCodeTheme = require('prism-react-renderer').themes.oceanicNext;
|
||||
|
||||
/** @type {import('@docusaurus/types').Config} */
|
||||
const config = {
|
||||
title: 'sern - Handlers. Redefined.',
|
||||
tagline: 'With the support of the community made plugins and a powerful CLI, it\'s more than just a handler.',
|
||||
url: 'https://sern.dev',
|
||||
baseUrl: '/',
|
||||
onBrokenLinks: 'ignore',
|
||||
onBrokenMarkdownLinks: 'warn',
|
||||
favicon: '/img/favicon.ico', // this currently not working
|
||||
|
||||
// GitHub pages deployment config.
|
||||
// If you aren't using GitHub pages, you don't need these.
|
||||
organizationName: 'sern-handler', // Usually your GitHub org/user name.
|
||||
projectName: 'website', // Usually your repo name.
|
||||
deploymentBranch: 'main',
|
||||
trailingSlash: false,
|
||||
|
||||
// Even if you don't use internalization, you can use this field to set useful
|
||||
// metadata like html lang. For example, if your site is Chinese, you may want
|
||||
// to replace "en" with "zh-Hans".
|
||||
i18n: {
|
||||
defaultLocale: 'en',
|
||||
locales: ['en']
|
||||
},
|
||||
markdown: {
|
||||
format: 'detect'
|
||||
},
|
||||
presets: [
|
||||
[
|
||||
'classic',
|
||||
/** @type {import('@docusaurus/preset-classic').Options} */
|
||||
({
|
||||
docs: {
|
||||
sidebarPath: require.resolve('./sidebars.js'),
|
||||
editUrl:
|
||||
'https://github.com/sern-handler/website/edit/main/',
|
||||
},
|
||||
blog: {
|
||||
showReadingTime: true,
|
||||
// Please change this to your repo.
|
||||
// Remove this to remove the "edit this page" links.
|
||||
editUrl:
|
||||
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
|
||||
blogSidebarCount: 'ALL',
|
||||
},
|
||||
pages: {
|
||||
path: 'src/pages',
|
||||
routeBasePath: '/',
|
||||
include: ['**/*.{js,jsx,ts,tsx,md,mdx}'],
|
||||
exclude: [
|
||||
'**/_*.{js,jsx,ts,tsx,md,mdx}',
|
||||
'**/_*/**',
|
||||
'**/*.test.{js,jsx,ts,tsx}',
|
||||
'**/__tests__/**',
|
||||
],
|
||||
},
|
||||
theme: {
|
||||
customCss: require.resolve('./src/css/custom.css'),
|
||||
},
|
||||
}),
|
||||
],
|
||||
],
|
||||
|
||||
themeConfig:
|
||||
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
|
||||
({
|
||||
image: 'https://sern.dev/img/logo.png',
|
||||
algolia: {
|
||||
appId: 'AA9S5J9NYT',
|
||||
apiKey: 'ccfe6abc4d12ac6f882565a9d0caafb1',
|
||||
indexName: 'sern',
|
||||
insights: true,
|
||||
container: 'div',
|
||||
debug: false,
|
||||
contextualSearch: true,
|
||||
externalUrlRegex: 'external\\.com|domain\\.com',
|
||||
replaceSearchResultPathname: {
|
||||
from: '/docs/api',
|
||||
to: '/docs/api',
|
||||
},
|
||||
searchParameters: {},
|
||||
searchPagePath: 'search',
|
||||
},
|
||||
navbar: {
|
||||
title: 'Home',
|
||||
logo: {
|
||||
alt: 'logo logo',
|
||||
src: 'img/favicon.ico',
|
||||
},
|
||||
items: [
|
||||
{
|
||||
type: 'doc',
|
||||
docId: 'intro',
|
||||
position: 'left',
|
||||
label: 'Docs & Guide',
|
||||
},
|
||||
{ to: '/blog', label: 'Blog', position: 'left' },
|
||||
{
|
||||
href: 'https://github.com/sern-handler',
|
||||
label: 'GitHub',
|
||||
position: 'right',
|
||||
},
|
||||
{
|
||||
to: '/plugins',
|
||||
label: 'Plugins',
|
||||
position: 'left'
|
||||
}
|
||||
],
|
||||
},
|
||||
footer: {
|
||||
style: 'dark',
|
||||
links: [
|
||||
{
|
||||
title: 'Information',
|
||||
items: [
|
||||
{
|
||||
label: 'Docs & Guide',
|
||||
to: '/docs/intro',
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
title: 'Community',
|
||||
items: [
|
||||
{
|
||||
label: 'Stack Overflow',
|
||||
href: 'https://stackoverflow.com/questions/tagged/sern-handler',
|
||||
},
|
||||
{
|
||||
label: 'Discord',
|
||||
href: 'https://discord.gg/DwbF5H5JgQ',
|
||||
},
|
||||
{
|
||||
label: 'Open Collective',
|
||||
href: 'https://opencollective.com/sern'
|
||||
}
|
||||
],
|
||||
},
|
||||
{
|
||||
title: 'More',
|
||||
items: [
|
||||
{
|
||||
label: 'Blog',
|
||||
to: '/blog',
|
||||
},
|
||||
{
|
||||
label: 'GitHub',
|
||||
href: 'https://github.com/sern-handler',
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
copyright: `Built with ❤️ by the sern Handler team and its contributors`,
|
||||
},
|
||||
metadata: [
|
||||
{ name: 'og:title', content: 'sern - Handlers. Redefined.' },
|
||||
{ name: 'og:description', content: 'A modular, customizable, fast Discord.js framework to streamline bot development' },
|
||||
{ name: 'og:url', content: 'https://sern.dev' },
|
||||
{ name: 'og:type', content: 'website' },
|
||||
{ name: 'twitter:site', content: '@sern-handler' },
|
||||
{ property: 'og:image:alt', content: 'sernlogo' },
|
||||
{ name: 'twitter:title', content: 'sern - Handlers. Redefined.' },
|
||||
{ name: 'twitter:description', content: 'A modular, customizable, fast Discord.js framework to streamline bot development' },
|
||||
{ name: 'keywords', content: 'discord, bot, handler, framework, documentation, sern' },
|
||||
{ name: 'twitter:image', content: 'https://sern.dev/img/logo.png' },
|
||||
{ name: 'twitter:url', content: 'https://sern.dev' },
|
||||
{ property: 'og:image:height', content: '512' },
|
||||
{ property: 'og:image:width', content: '1024' },
|
||||
{ name: 'theme-color', content: '#F25186' }
|
||||
],
|
||||
prism: {
|
||||
theme: lightCodeTheme,
|
||||
darkTheme: darkCodeTheme,
|
||||
},
|
||||
}),
|
||||
plugins: [
|
||||
[
|
||||
'docusaurus-plugin-typedoc',
|
||||
{
|
||||
//if you're editing website, please change this to your local branch of sern to generate documentation
|
||||
entryPoints: ['../sernHandlerV2/src/index.ts'],
|
||||
tsconfig: '../sernHandlerV2/tsconfig.json',
|
||||
},
|
||||
],
|
||||
[
|
||||
"@dipakparmar/docusaurus-plugin-umami",
|
||||
{
|
||||
websiteID: "e82ff65c-b08f-47b5-8e74-5c31cbcec0ad",
|
||||
analyticsDomain: "analytics.srizan.dev",
|
||||
scriptName: 'ua.js',
|
||||
dataAutoTrack: true,
|
||||
dataDoNotTrack: true,
|
||||
dataCache: true,
|
||||
dataDomains: "sern.dev",
|
||||
},
|
||||
]
|
||||
]
|
||||
};
|
||||
|
||||
module.exports = config;
|
||||
@@ -6,9 +6,9 @@ sidebar_position: 0
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
**`Deprecated`**
|
||||
**`Experimental`**
|
||||
|
||||
Will be removed in future
|
||||
Will be refactored / changed in future
|
||||
|
||||
## Type parameters
|
||||
|
||||
@@ -20,7 +20,7 @@ Will be removed in future
|
||||
|
||||
### constructor
|
||||
|
||||
• **new CommandExecutable**<`Type`\>(): [`CommandExecutable`](CommandExecutable.md)<`Type`\>
|
||||
• **new CommandExecutable**<`Type`\>()
|
||||
|
||||
#### Type parameters
|
||||
|
||||
@@ -28,10 +28,6 @@ Will be removed in future
|
||||
| :------ | :------ |
|
||||
| `Type` | extends [`CommandType`](../enums/CommandType.md) = [`CommandType`](../enums/CommandType.md) |
|
||||
|
||||
#### Returns
|
||||
|
||||
[`CommandExecutable`](CommandExecutable.md)<`Type`\>
|
||||
|
||||
## Properties
|
||||
|
||||
### plugins
|
||||
@@ -40,7 +36,7 @@ Will be removed in future
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:80](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L80)
|
||||
[src/core/modules.ts:79](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L79)
|
||||
|
||||
___
|
||||
|
||||
@@ -50,7 +46,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:79](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L79)
|
||||
[src/core/modules.ts:78](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L78)
|
||||
|
||||
___
|
||||
|
||||
@@ -60,13 +56,13 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:81](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L81)
|
||||
[src/core/modules.ts:80](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L80)
|
||||
|
||||
## Methods
|
||||
|
||||
### execute
|
||||
|
||||
▸ **execute**(`...args`): `unknown`
|
||||
▸ `Abstract` **execute**(`...args`): `unknown`
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -80,13 +76,13 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:92](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L92)
|
||||
[src/core/modules.ts:91](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L91)
|
||||
|
||||
___
|
||||
|
||||
### getInstance
|
||||
|
||||
▸ **getInstance**(): [`CommandModule`](../modules.md#commandmodule)
|
||||
▸ `Static` **getInstance**(): [`CommandModule`](../modules.md#commandmodule)
|
||||
|
||||
#### Returns
|
||||
|
||||
@@ -94,4 +90,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:83](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L83)
|
||||
[src/core/modules.ts:82](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L82)
|
||||
|
||||
@@ -22,7 +22,7 @@ Message and ChatInputCommandInteraction
|
||||
|
||||
### constructor
|
||||
|
||||
• **new Context**(`ctx`): [`Context`](Context.md)
|
||||
• `Protected` **new Context**(`ctx`)
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -30,17 +30,13 @@ Message and ChatInputCommandInteraction
|
||||
| :------ | :------ |
|
||||
| `ctx` | `Result`<`Message`<`boolean`\>, `ChatInputCommandInteraction`<`CacheType`\>\> |
|
||||
|
||||
#### Returns
|
||||
|
||||
[`Context`](Context.md)
|
||||
|
||||
#### Overrides
|
||||
|
||||
CoreContext\<Message, ChatInputCommandInteraction\>.constructor
|
||||
CoreContext<Message, ChatInputCommandInteraction\>.constructor
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:29](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L29)
|
||||
[src/core/structures/context.ts:29](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L29)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -54,7 +50,7 @@ CoreContext.ctx
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:29](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L29)
|
||||
[src/core/structures/context.ts:29](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L29)
|
||||
|
||||
## Accessors
|
||||
|
||||
@@ -68,21 +64,7 @@ CoreContext.ctx
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:39](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L39)
|
||||
|
||||
___
|
||||
|
||||
### channelId
|
||||
|
||||
• `get` **channelId**(): `string`
|
||||
|
||||
#### Returns
|
||||
|
||||
`string`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:45](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L45)
|
||||
[src/core/structures/context.ts:37](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L37)
|
||||
|
||||
___
|
||||
|
||||
@@ -96,7 +78,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:91](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L91)
|
||||
[src/core/structures/context.ts:66](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L66)
|
||||
|
||||
___
|
||||
|
||||
@@ -110,7 +92,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:65](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L65)
|
||||
[src/core/structures/context.ts:48](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L48)
|
||||
|
||||
___
|
||||
|
||||
@@ -124,7 +106,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:71](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L71)
|
||||
[src/core/structures/context.ts:52](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L52)
|
||||
|
||||
___
|
||||
|
||||
@@ -138,7 +120,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:77](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L77)
|
||||
[src/core/structures/context.ts:56](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L56)
|
||||
|
||||
___
|
||||
|
||||
@@ -152,7 +134,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L33)
|
||||
[src/core/structures/context.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -166,7 +148,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:97](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L97)
|
||||
[src/core/structures/context.ts:70](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L70)
|
||||
|
||||
___
|
||||
|
||||
@@ -184,7 +166,7 @@ CoreContext.interaction
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/core-context.ts:15](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/core-context.ts#L15)
|
||||
[src/core/structures/core-context.ts:15](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/core-context.ts#L15)
|
||||
|
||||
___
|
||||
|
||||
@@ -198,7 +180,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:85](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L85)
|
||||
[src/core/structures/context.ts:62](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L62)
|
||||
|
||||
___
|
||||
|
||||
@@ -216,7 +198,7 @@ CoreContext.message
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/core-context.ts:12](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/core-context.ts#L12)
|
||||
[src/core/structures/core-context.ts:12](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/core-context.ts#L12)
|
||||
|
||||
___
|
||||
|
||||
@@ -234,7 +216,7 @@ CoreContext.options
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:26](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L26)
|
||||
[src/core/structures/context.ts:26](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L26)
|
||||
|
||||
___
|
||||
|
||||
@@ -251,21 +233,7 @@ else, interaction.user
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:55](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L55)
|
||||
|
||||
___
|
||||
|
||||
### userId
|
||||
|
||||
• `get` **userId**(): `string`
|
||||
|
||||
#### Returns
|
||||
|
||||
`string`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:61](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L61)
|
||||
[src/core/structures/context.ts:44](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L44)
|
||||
|
||||
## Methods
|
||||
|
||||
@@ -283,7 +251,7 @@ CoreContext.isMessage
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/core-context.ts:19](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/core-context.ts#L19)
|
||||
[src/core/structures/core-context.ts:19](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/core-context.ts#L19)
|
||||
|
||||
___
|
||||
|
||||
@@ -301,7 +269,7 @@ CoreContext.isSlash
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/core-context.ts:23](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/core-context.ts#L23)
|
||||
[src/core/structures/core-context.ts:23](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/core-context.ts#L23)
|
||||
|
||||
___
|
||||
|
||||
@@ -321,13 +289,13 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:103](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L103)
|
||||
[src/core/structures/context.ts:74](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L74)
|
||||
|
||||
___
|
||||
|
||||
### wrap
|
||||
|
||||
▸ **wrap**(`wrappable`): [`Context`](Context.md)
|
||||
▸ `Static` **wrap**(`wrappable`): [`Context`](Context.md)
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -345,4 +313,4 @@ CoreContext.wrap
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/context.ts:113](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/context.ts#L113)
|
||||
[src/core/structures/context.ts:84](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/context.ts#L84)
|
||||
|
||||
@@ -9,7 +9,7 @@ custom_edit_url: null
|
||||
**`Since`**
|
||||
|
||||
2.0.0
|
||||
Version 4.0.0 will internalize this api. Please refrain from using the defaults!
|
||||
Version 4.0.0 will internalize this api. Please refrain from using ModuleStore!
|
||||
|
||||
## Implements
|
||||
|
||||
@@ -19,21 +19,23 @@ Version 4.0.0 will internalize this api. Please refrain from using the defaults!
|
||||
|
||||
### constructor
|
||||
|
||||
• **new DefaultErrorHandling**(): [`DefaultErrorHandling`](DefaultErrorHandling.md)
|
||||
|
||||
#### Returns
|
||||
|
||||
[`DefaultErrorHandling`](DefaultErrorHandling.md)
|
||||
• **new DefaultErrorHandling**()
|
||||
|
||||
## Properties
|
||||
|
||||
### #keepAlive
|
||||
### keepAlive
|
||||
|
||||
• `Private` **#keepAlive**: `number` = `5`
|
||||
• **keepAlive**: `number` = `5`
|
||||
|
||||
Number of times the process should throw an error until crashing and exiting
|
||||
|
||||
#### Implementation of
|
||||
|
||||
[ErrorHandling](../interfaces/ErrorHandling.md).[keepAlive](../interfaces/ErrorHandling.md#keepalive)
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/error-handling.ts:13](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/error-handling.ts#L13)
|
||||
[src/core/structures/services/error-handling.ts:13](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/error-handling.ts#L13)
|
||||
|
||||
## Methods
|
||||
|
||||
@@ -41,6 +43,10 @@ Version 4.0.0 will internalize this api. Please refrain from using the defaults!
|
||||
|
||||
▸ **crash**(`err`): `never`
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
Version 4 will remove this method
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -51,17 +57,13 @@ Version 4.0.0 will internalize this api. Please refrain from using the defaults!
|
||||
|
||||
`never`
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
Version 4 will remove this method
|
||||
|
||||
#### Implementation of
|
||||
|
||||
[ErrorHandling](../interfaces/ErrorHandling.md).[crash](../interfaces/ErrorHandling.md#crash)
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/error-handling.ts:9](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/error-handling.ts#L9)
|
||||
[src/core/structures/services/error-handling.ts:9](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/error-handling.ts#L9)
|
||||
|
||||
___
|
||||
|
||||
@@ -69,7 +71,8 @@ ___
|
||||
|
||||
▸ **updateAlive**(`err`): `void`
|
||||
|
||||
A function that is called on every throw.
|
||||
A function that is called on every crash. Updates keepAlive.
|
||||
If keepAlive is 0, the process crashes.
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -87,4 +90,4 @@ A function that is called on every throw.
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/error-handling.ts:15](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/error-handling.ts#L15)
|
||||
[src/core/structures/services/error-handling.ts:15](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/error-handling.ts#L15)
|
||||
|
||||
@@ -19,17 +19,13 @@ Version 4.0.0 will internalize this api. Please refrain from using ModuleStore!
|
||||
|
||||
### constructor
|
||||
|
||||
• **new DefaultLogging**(): [`DefaultLogging`](DefaultLogging.md)
|
||||
|
||||
#### Returns
|
||||
|
||||
[`DefaultLogging`](DefaultLogging.md)
|
||||
• **new DefaultLogging**()
|
||||
|
||||
## Methods
|
||||
|
||||
### date
|
||||
|
||||
▸ **date**(): `Date`
|
||||
▸ `Private` **date**(): `Date`
|
||||
|
||||
#### Returns
|
||||
|
||||
@@ -37,7 +33,7 @@ Version 4.0.0 will internalize this api. Please refrain from using ModuleStore!
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/logger.ts:9](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/logger.ts#L9)
|
||||
[src/core/structures/services/logger.ts:9](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/logger.ts#L9)
|
||||
|
||||
___
|
||||
|
||||
@@ -61,7 +57,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/logger.ts:10](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/logger.ts#L10)
|
||||
[src/core/structures/services/logger.ts:10](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/logger.ts#L10)
|
||||
|
||||
___
|
||||
|
||||
@@ -85,7 +81,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/logger.ts:14](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/logger.ts#L14)
|
||||
[src/core/structures/services/logger.ts:14](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/logger.ts#L14)
|
||||
|
||||
___
|
||||
|
||||
@@ -109,7 +105,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/logger.ts:18](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/logger.ts#L18)
|
||||
[src/core/structures/services/logger.ts:18](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/logger.ts#L18)
|
||||
|
||||
___
|
||||
|
||||
@@ -133,4 +129,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/logger.ts:22](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/logger.ts#L22)
|
||||
[src/core/structures/services/logger.ts:22](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/logger.ts#L22)
|
||||
|
||||
@@ -19,7 +19,7 @@ Version 4.0.0 will internalize this api. Please refrain from using DefaultModule
|
||||
|
||||
### constructor
|
||||
|
||||
• **new DefaultModuleManager**(`moduleStore`): [`DefaultModuleManager`](DefaultModuleManager.md)
|
||||
• **new DefaultModuleManager**(`moduleStore`)
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -27,13 +27,9 @@ Version 4.0.0 will internalize this api. Please refrain from using DefaultModule
|
||||
| :------ | :------ |
|
||||
| `moduleStore` | [`CoreModuleStore`](../interfaces/CoreModuleStore.md) |
|
||||
|
||||
#### Returns
|
||||
|
||||
[`DefaultModuleManager`](DefaultModuleManager.md)
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:11](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L11)
|
||||
[src/core/structures/services/module-manager.ts:12](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L12)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -43,13 +39,13 @@ Version 4.0.0 will internalize this api. Please refrain from using DefaultModule
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:11](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L11)
|
||||
[src/core/structures/services/module-manager.ts:12](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L12)
|
||||
|
||||
## Methods
|
||||
|
||||
### get
|
||||
|
||||
▸ **get**(`id`): `undefined` \| `Module`
|
||||
▸ **get**(`id`): `undefined` \| `string`
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -59,7 +55,7 @@ Version 4.0.0 will internalize this api. Please refrain from using DefaultModule
|
||||
|
||||
#### Returns
|
||||
|
||||
`undefined` \| `Module`
|
||||
`undefined` \| `string`
|
||||
|
||||
#### Implementation of
|
||||
|
||||
@@ -67,13 +63,13 @@ Version 4.0.0 will internalize this api. Please refrain from using DefaultModule
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L34)
|
||||
[src/core/structures/services/module-manager.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
### getByNameCommandType
|
||||
|
||||
▸ **getByNameCommandType**<`T`\>(`name`, `commandType`): `undefined` \| [`CommandModuleDefs`](../interfaces/CommandModuleDefs.md)[`T`]
|
||||
▸ **getByNameCommandType**<`T`\>(`name`, `commandType`): `undefined` \| `Promise`<[`CommandModuleDefs`](../interfaces/CommandModuleDefs.md)[`T`]\>
|
||||
|
||||
#### Type parameters
|
||||
|
||||
@@ -90,7 +86,7 @@ ___
|
||||
|
||||
#### Returns
|
||||
|
||||
`undefined` \| [`CommandModuleDefs`](../interfaces/CommandModuleDefs.md)[`T`]
|
||||
`undefined` \| `Promise`<[`CommandModuleDefs`](../interfaces/CommandModuleDefs.md)[`T`]\>
|
||||
|
||||
#### Implementation of
|
||||
|
||||
@@ -98,7 +94,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:14](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L14)
|
||||
[src/core/structures/services/module-manager.ts:14](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L14)
|
||||
|
||||
___
|
||||
|
||||
@@ -122,19 +118,17 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:26](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L26)
|
||||
[src/core/structures/services/module-manager.ts:26](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L26)
|
||||
|
||||
___
|
||||
|
||||
### getPublishableCommands
|
||||
|
||||
▸ **getPublishableCommands**(): [`CommandModule`](../modules.md#commandmodule)[]
|
||||
▸ **getPublishableCommands**(): `Promise`<[`CommandModule`](../modules.md#commandmodule)[]\>
|
||||
|
||||
#### Returns
|
||||
|
||||
[`CommandModule`](../modules.md#commandmodule)[]
|
||||
|
||||
**`Deprecated`**
|
||||
`Promise`<[`CommandModule`](../modules.md#commandmodule)[]\>
|
||||
|
||||
#### Implementation of
|
||||
|
||||
@@ -142,7 +136,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:41](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L41)
|
||||
[src/core/structures/services/module-manager.ts:41](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L41)
|
||||
|
||||
___
|
||||
|
||||
@@ -155,7 +149,7 @@ ___
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `id` | `string` |
|
||||
| `path` | [`CommandModule`](../modules.md#commandmodule) |
|
||||
| `path` | `string` |
|
||||
|
||||
#### Returns
|
||||
|
||||
@@ -167,7 +161,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:37](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L37)
|
||||
[src/core/structures/services/module-manager.ts:37](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L37)
|
||||
|
||||
___
|
||||
|
||||
@@ -192,4 +186,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/services/module-manager.ts:22](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/services/module-manager.ts#L22)
|
||||
[src/core/structures/services/module-manager.ts:22](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/services/module-manager.ts#L22)
|
||||
|
||||
@@ -6,9 +6,9 @@ sidebar_position: 0
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
**`Deprecated`**
|
||||
**`Experimental`**
|
||||
|
||||
Will be removed in future
|
||||
Will be refactored in future
|
||||
|
||||
## Type parameters
|
||||
|
||||
@@ -20,7 +20,7 @@ Will be removed in future
|
||||
|
||||
### constructor
|
||||
|
||||
• **new EventExecutable**<`Type`\>(): [`EventExecutable`](EventExecutable.md)<`Type`\>
|
||||
• **new EventExecutable**<`Type`\>()
|
||||
|
||||
#### Type parameters
|
||||
|
||||
@@ -28,10 +28,6 @@ Will be removed in future
|
||||
| :------ | :------ |
|
||||
| `Type` | extends [`EventType`](../enums/EventType.md) |
|
||||
|
||||
#### Returns
|
||||
|
||||
[`EventExecutable`](EventExecutable.md)<`Type`\>
|
||||
|
||||
## Properties
|
||||
|
||||
### plugins
|
||||
@@ -40,7 +36,7 @@ Will be removed in future
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:101](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L101)
|
||||
[src/core/modules.ts:100](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L100)
|
||||
|
||||
___
|
||||
|
||||
@@ -50,7 +46,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:100](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L100)
|
||||
[src/core/modules.ts:99](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L99)
|
||||
|
||||
___
|
||||
|
||||
@@ -60,13 +56,13 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:103](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L103)
|
||||
[src/core/modules.ts:102](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L102)
|
||||
|
||||
## Methods
|
||||
|
||||
### execute
|
||||
|
||||
▸ **execute**(`...args`): `unknown`
|
||||
▸ `Abstract` **execute**(`...args`): `unknown`
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -80,13 +76,13 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:112](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L112)
|
||||
[src/core/modules.ts:111](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L111)
|
||||
|
||||
___
|
||||
|
||||
### getInstance
|
||||
|
||||
▸ **getInstance**(): [`EventModule`](../modules.md#eventmodule)
|
||||
▸ `Static` **getInstance**(): [`EventModule`](../modules.md#eventmodule)
|
||||
|
||||
#### Returns
|
||||
|
||||
@@ -94,4 +90,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:104](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L104)
|
||||
[src/core/modules.ts:103](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L103)
|
||||
|
||||
@@ -6,25 +6,31 @@ sidebar_position: 0
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
Represents a core module store that stores IDs mapped to file paths.
|
||||
|
||||
## Implements
|
||||
|
||||
- [`CoreModuleStore`](../interfaces/CoreModuleStore.md)
|
||||
|
||||
## Constructors
|
||||
|
||||
### constructor
|
||||
|
||||
• **new ModuleStore**(): [`ModuleStore`](ModuleStore.md)
|
||||
|
||||
#### Returns
|
||||
|
||||
[`ModuleStore`](ModuleStore.md)
|
||||
• **new ModuleStore**()
|
||||
|
||||
## Properties
|
||||
|
||||
### commands
|
||||
|
||||
• **commands**: `Map`<`string`, `Module`\>
|
||||
• **commands**: `Map`<`string`, `string`\>
|
||||
|
||||
#### Implementation of
|
||||
|
||||
[CoreModuleStore](../interfaces/CoreModuleStore.md).[commands](../interfaces/CoreModuleStore.md#commands)
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/module-store.ts:10](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/module-store.ts#L10)
|
||||
[src/core/structures/module-store.ts:11](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/module-store.ts#L11)
|
||||
|
||||
___
|
||||
|
||||
@@ -32,6 +38,10 @@ ___
|
||||
|
||||
• **metadata**: `WeakMap`<`Module`, `CommandMeta`\>
|
||||
|
||||
#### Implementation of
|
||||
|
||||
[CoreModuleStore](../interfaces/CoreModuleStore.md).[metadata](../interfaces/CoreModuleStore.md#metadata)
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/module-store.ts:9](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/module-store.ts#L9)
|
||||
[src/core/structures/module-store.ts:10](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/module-store.ts#L10)
|
||||
|
||||
@@ -20,11 +20,7 @@ custom_edit_url: null
|
||||
|
||||
### constructor
|
||||
|
||||
• **new SernEmitter**(): [`SernEmitter`](SernEmitter.md)
|
||||
|
||||
#### Returns
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
• **new SernEmitter**()
|
||||
|
||||
#### Overrides
|
||||
|
||||
@@ -32,7 +28,7 @@ EventEmitter.constructor
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:10](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L10)
|
||||
[src/core/structures/sern-emitter.ts:10](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L10)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -46,7 +42,7 @@ EventEmitter.captureRejectionSymbol
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:357
|
||||
node_modules/@types/node/events.d.ts:328
|
||||
|
||||
___
|
||||
|
||||
@@ -62,7 +58,7 @@ EventEmitter.captureRejections
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:362
|
||||
node_modules/@types/node/events.d.ts:333
|
||||
|
||||
___
|
||||
|
||||
@@ -76,7 +72,7 @@ EventEmitter.defaultMaxListeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:363
|
||||
node_modules/@types/node/events.d.ts:334
|
||||
|
||||
___
|
||||
|
||||
@@ -98,7 +94,7 @@ EventEmitter.errorMonitor
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:356
|
||||
node_modules/@types/node/events.d.ts:327
|
||||
|
||||
## Methods
|
||||
|
||||
@@ -108,6 +104,10 @@ node_modules/@types/node/events.d.ts:356
|
||||
|
||||
Alias for `emitter.on(eventName, listener)`.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -119,17 +119,13 @@ Alias for `emitter.on(eventName, listener)`.
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.addListener
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:383
|
||||
node_modules/@types/node/events.d.ts:354
|
||||
|
||||
___
|
||||
|
||||
@@ -162,7 +158,7 @@ EventEmitter.emit
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:40](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L40)
|
||||
[src/core/structures/sern-emitter.ts:40](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L40)
|
||||
|
||||
___
|
||||
|
||||
@@ -186,21 +182,21 @@ console.log(myEE.eventNames());
|
||||
// Prints: [ 'foo', 'bar', Symbol(symbol) ]
|
||||
```
|
||||
|
||||
#### Returns
|
||||
|
||||
(`string` \| `symbol`)[]
|
||||
|
||||
**`Since`**
|
||||
|
||||
v6.0.0
|
||||
|
||||
#### Returns
|
||||
|
||||
(`string` \| `symbol`)[]
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.eventNames
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:702
|
||||
node_modules/@types/node/events.d.ts:673
|
||||
|
||||
___
|
||||
|
||||
@@ -211,21 +207,21 @@ ___
|
||||
Returns the current max listener value for the `EventEmitter` which is either
|
||||
set by `emitter.setMaxListeners(n)` or defaults to [defaultMaxListeners](SernEmitter.md#defaultmaxlisteners).
|
||||
|
||||
#### Returns
|
||||
|
||||
`number`
|
||||
|
||||
**`Since`**
|
||||
|
||||
v1.0.0
|
||||
|
||||
#### Returns
|
||||
|
||||
`number`
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.getMaxListeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:555
|
||||
node_modules/@types/node/events.d.ts:526
|
||||
|
||||
___
|
||||
|
||||
@@ -238,6 +234,10 @@ Returns the number of listeners listening to the event named `eventName`.
|
||||
If `listener` is provided, it will return how many times the listener
|
||||
is found in the list of the listeners of the event.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v3.2.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type | Description |
|
||||
@@ -249,17 +249,13 @@ is found in the list of the listeners of the event.
|
||||
|
||||
`number`
|
||||
|
||||
**`Since`**
|
||||
|
||||
v3.2.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.listenerCount
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:649
|
||||
node_modules/@types/node/events.d.ts:620
|
||||
|
||||
___
|
||||
|
||||
@@ -277,6 +273,10 @@ console.log(util.inspect(server.listeners('connection')));
|
||||
// Prints: [ [Function] ]
|
||||
```
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -287,17 +287,13 @@ console.log(util.inspect(server.listeners('connection')));
|
||||
|
||||
`Function`[]
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.listeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:568
|
||||
node_modules/@types/node/events.d.ts:539
|
||||
|
||||
___
|
||||
|
||||
@@ -307,6 +303,10 @@ ___
|
||||
|
||||
Alias for `emitter.removeListener()`.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v10.0.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -318,17 +318,13 @@ Alias for `emitter.removeListener()`.
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
|
||||
**`Since`**
|
||||
|
||||
v10.0.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.off
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:528
|
||||
node_modules/@types/node/events.d.ts:499
|
||||
|
||||
___
|
||||
|
||||
@@ -361,7 +357,7 @@ EventEmitter.on
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:18](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L18)
|
||||
[src/core/structures/sern-emitter.ts:18](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L18)
|
||||
|
||||
___
|
||||
|
||||
@@ -394,7 +390,7 @@ EventEmitter.once
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:29](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L29)
|
||||
[src/core/structures/sern-emitter.ts:29](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L29)
|
||||
|
||||
___
|
||||
|
||||
@@ -415,6 +411,10 @@ server.prependListener('connection', (stream) => {
|
||||
|
||||
Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v6.0.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type | Description |
|
||||
@@ -426,17 +426,13 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
|
||||
**`Since`**
|
||||
|
||||
v6.0.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.prependListener
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:667
|
||||
node_modules/@types/node/events.d.ts:638
|
||||
|
||||
___
|
||||
|
||||
@@ -455,6 +451,10 @@ server.prependOnceListener('connection', (stream) => {
|
||||
|
||||
Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v6.0.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type | Description |
|
||||
@@ -466,17 +466,13 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
|
||||
**`Since`**
|
||||
|
||||
v6.0.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.prependOnceListener
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:683
|
||||
node_modules/@types/node/events.d.ts:654
|
||||
|
||||
___
|
||||
|
||||
@@ -511,6 +507,10 @@ newListeners[0]();
|
||||
emitter.emit('log');
|
||||
```
|
||||
|
||||
**`Since`**
|
||||
|
||||
v9.4.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -521,17 +521,13 @@ emitter.emit('log');
|
||||
|
||||
`Function`[]
|
||||
|
||||
**`Since`**
|
||||
|
||||
v9.4.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.rawListeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:598
|
||||
node_modules/@types/node/events.d.ts:569
|
||||
|
||||
___
|
||||
|
||||
@@ -547,6 +543,10 @@ component or module (e.g. sockets or file streams).
|
||||
|
||||
Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -557,17 +557,13 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.removeAllListeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:539
|
||||
node_modules/@types/node/events.d.ts:510
|
||||
|
||||
___
|
||||
|
||||
@@ -652,6 +648,10 @@ ee.emit('ping');
|
||||
|
||||
Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -663,17 +663,13 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.1.26
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.removeListener
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:523
|
||||
node_modules/@types/node/events.d.ts:494
|
||||
|
||||
___
|
||||
|
||||
@@ -688,6 +684,10 @@ modified for this specific `EventEmitter` instance. The value can be set to`Infi
|
||||
|
||||
Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.3.5
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -698,23 +698,19 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
|
||||
|
||||
[`SernEmitter`](SernEmitter.md)
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.3.5
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.setMaxListeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:549
|
||||
node_modules/@types/node/events.d.ts:520
|
||||
|
||||
___
|
||||
|
||||
### failure
|
||||
|
||||
▸ **failure**(`module?`, `reason?`): `Object`
|
||||
▸ `Static` **failure**(`module?`, `reason?`): `Object`
|
||||
|
||||
Creates a compliant SernEmitter failure payload
|
||||
|
||||
@@ -729,21 +725,15 @@ Creates a compliant SernEmitter failure payload
|
||||
|
||||
`Object`
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `module?` | `AnyModule` |
|
||||
| `reason` | `string` \| `Error` |
|
||||
| `type` | [`Failure`](../enums/PayloadType.md#failure) |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:59](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L59)
|
||||
[src/core/structures/sern-emitter.ts:59](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L59)
|
||||
|
||||
___
|
||||
|
||||
### getEventListeners
|
||||
|
||||
▸ **getEventListeners**(`emitter`, `name`): `Function`[]
|
||||
▸ `Static` **getEventListeners**(`emitter`, `name`): `Function`[]
|
||||
|
||||
Returns a copy of the array of listeners for the event named `eventName`.
|
||||
|
||||
@@ -770,6 +760,10 @@ const { getEventListeners, EventEmitter } = require('events');
|
||||
}
|
||||
```
|
||||
|
||||
**`Since`**
|
||||
|
||||
v15.2.0, v14.17.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -781,10 +775,6 @@ const { getEventListeners, EventEmitter } = require('events');
|
||||
|
||||
`Function`[]
|
||||
|
||||
**`Since`**
|
||||
|
||||
v15.2.0, v14.17.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.getEventListeners
|
||||
@@ -795,63 +785,9 @@ node_modules/@types/node/events.d.ts:299
|
||||
|
||||
___
|
||||
|
||||
### getMaxListeners
|
||||
|
||||
▸ **getMaxListeners**(`emitter`): `number`
|
||||
|
||||
Returns the currently set max amount of listeners.
|
||||
|
||||
For `EventEmitter`s this behaves exactly the same as calling `.getMaxListeners` on
|
||||
the emitter.
|
||||
|
||||
For `EventTarget`s this is the only way to get the max event listeners for the
|
||||
event target. If the number of event handlers on a single EventTarget exceeds
|
||||
the max set, the EventTarget will print a warning.
|
||||
|
||||
```js
|
||||
import { getMaxListeners, setMaxListeners, EventEmitter } from 'node:events';
|
||||
|
||||
{
|
||||
const ee = new EventEmitter();
|
||||
console.log(getMaxListeners(ee)); // 10
|
||||
setMaxListeners(11, ee);
|
||||
console.log(getMaxListeners(ee)); // 11
|
||||
}
|
||||
{
|
||||
const et = new EventTarget();
|
||||
console.log(getMaxListeners(et)); // 10
|
||||
setMaxListeners(11, et);
|
||||
console.log(getMaxListeners(et)); // 11
|
||||
}
|
||||
```
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `emitter` | `EventEmitter` \| `_DOMEventTarget` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`number`
|
||||
|
||||
**`Since`**
|
||||
|
||||
v18.17.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.getMaxListeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:328
|
||||
|
||||
___
|
||||
|
||||
### listenerCount
|
||||
|
||||
▸ **listenerCount**(`emitter`, `eventName`): `number`
|
||||
▸ `Static` **listenerCount**(`emitter`, `eventName`): `number`
|
||||
|
||||
A class method that returns the number of listeners for the given `eventName`registered on the given `emitter`.
|
||||
|
||||
@@ -864,6 +800,14 @@ console.log(listenerCount(myEmitter, 'event'));
|
||||
// Prints: 2
|
||||
```
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.9.12
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
Since v3.2.0 - Use `listenerCount` instead.
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type | Description |
|
||||
@@ -875,14 +819,6 @@ console.log(listenerCount(myEmitter, 'event'));
|
||||
|
||||
`number`
|
||||
|
||||
**`Since`**
|
||||
|
||||
v0.9.12
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
Since v3.2.0 - Use `listenerCount` instead.
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.listenerCount
|
||||
@@ -895,7 +831,7 @@ ___
|
||||
|
||||
### on
|
||||
|
||||
▸ **on**(`emitter`, `eventName`, `options?`): `AsyncIterableIterator`<`any`\>
|
||||
▸ `Static` **on**(`emitter`, `eventName`, `options?`): `AsyncIterableIterator`<`any`\>
|
||||
|
||||
```js
|
||||
const { on, EventEmitter } = require('events');
|
||||
@@ -951,6 +887,10 @@ const ac = new AbortController();
|
||||
process.nextTick(() => ac.abort());
|
||||
```
|
||||
|
||||
**`Since`**
|
||||
|
||||
v13.6.0, v12.16.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type | Description |
|
||||
@@ -965,10 +905,6 @@ process.nextTick(() => ac.abort());
|
||||
|
||||
that iterates `eventName` events emitted by the `emitter`
|
||||
|
||||
**`Since`**
|
||||
|
||||
v13.6.0, v12.16.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.on
|
||||
@@ -977,25 +913,25 @@ EventEmitter.on
|
||||
|
||||
node_modules/@types/node/events.d.ts:254
|
||||
|
||||
▸ **on**<`Emitter`, `Events`\>(`eventEmitter`, `eventName`): `AsyncIterableIterator`<`Emitter` extends `Client`<`boolean`\> ? `ClientEvents`[`Events`] : `any`\>
|
||||
▸ `Static` **on**<`E`, `K`\>(`eventEmitter`, `eventName`): `AsyncIterableIterator`<`E` extends `Client`<`boolean`\> ? `ClientEvents`[`K`] : `any`\>
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `Emitter` | extends `__module` |
|
||||
| `Events` | extends keyof `ClientEvents` |
|
||||
| `E` | extends `__module` |
|
||||
| `K` | extends keyof `ClientEvents` |
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `eventEmitter` | `Emitter` |
|
||||
| `eventName` | `Emitter` extends `Client`<`boolean`\> ? `Events` : `string` |
|
||||
| `eventEmitter` | `E` |
|
||||
| `eventName` | `E` extends `Client`<`boolean`\> ? `K` : `string` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`AsyncIterableIterator`<`Emitter` extends `Client`<`boolean`\> ? `ClientEvents`[`Events`] : `any`\>
|
||||
`AsyncIterableIterator`<`E` extends `Client`<`boolean`\> ? `ClientEvents`[`K`] : `any`\>
|
||||
|
||||
#### Inherited from
|
||||
|
||||
@@ -1003,13 +939,13 @@ EventEmitter.on
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:243
|
||||
node_modules/discord.js/typings/index.d.ts:229
|
||||
|
||||
___
|
||||
|
||||
### once
|
||||
|
||||
▸ **once**(`emitter`, `eventName`, `options?`): `Promise`<`any`[]\>
|
||||
▸ `Static` **once**(`emitter`, `eventName`, `options?`): `Promise`<`any`[]\>
|
||||
|
||||
Creates a `Promise` that is fulfilled when the `EventEmitter` emits the given
|
||||
event or that is rejected if the `EventEmitter` emits `'error'` while waiting.
|
||||
@@ -1091,6 +1027,10 @@ ac.abort(); // Abort waiting for the event
|
||||
ee.emit('foo'); // Prints: Waiting for the event was canceled!
|
||||
```
|
||||
|
||||
**`Since`**
|
||||
|
||||
v11.13.0, v10.16.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -1103,10 +1043,6 @@ ee.emit('foo'); // Prints: Waiting for the event was canceled!
|
||||
|
||||
`Promise`<`any`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
v11.13.0, v10.16.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.once
|
||||
@@ -1115,7 +1051,7 @@ EventEmitter.once
|
||||
|
||||
node_modules/@types/node/events.d.ts:194
|
||||
|
||||
▸ **once**(`emitter`, `eventName`, `options?`): `Promise`<`any`[]\>
|
||||
▸ `Static` **once**(`emitter`, `eventName`, `options?`): `Promise`<`any`[]\>
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -1137,25 +1073,25 @@ EventEmitter.once
|
||||
|
||||
node_modules/@types/node/events.d.ts:195
|
||||
|
||||
▸ **once**<`Emitter`, `Event`\>(`eventEmitter`, `eventName`): `Promise`<`Emitter` extends `Client`<`boolean`\> ? `ClientEvents`[`Event`] : `any`[]\>
|
||||
▸ `Static` **once**<`E`, `K`\>(`eventEmitter`, `eventName`): `Promise`<`E` extends `Client`<`boolean`\> ? `ClientEvents`[`K`] : `any`[]\>
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `Emitter` | extends `__module` |
|
||||
| `Event` | extends keyof `ClientEvents` |
|
||||
| `E` | extends `__module` |
|
||||
| `K` | extends keyof `ClientEvents` |
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `eventEmitter` | `Emitter` |
|
||||
| `eventName` | `Emitter` extends `Client`<`boolean`\> ? `Event` : `string` |
|
||||
| `eventEmitter` | `E` |
|
||||
| `eventName` | `E` extends `Client`<`boolean`\> ? `K` : `string` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`Promise`<`Emitter` extends `Client`<`boolean`\> ? `ClientEvents`[`Event`] : `any`[]\>
|
||||
`Promise`<`E` extends `Client`<`boolean`\> ? `ClientEvents`[`K`] : `any`[]\>
|
||||
|
||||
#### Inherited from
|
||||
|
||||
@@ -1163,13 +1099,13 @@ EventEmitter.once
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:239
|
||||
node_modules/discord.js/typings/index.d.ts:225
|
||||
|
||||
___
|
||||
|
||||
### payload
|
||||
|
||||
▸ **payload**<`T`\>(`type`, `module?`, `reason?`): `T`
|
||||
▸ `Static` `Private` **payload**<`T`\>(`type`, `module?`, `reason?`): `T`
|
||||
|
||||
#### Type parameters
|
||||
|
||||
@@ -1191,13 +1127,13 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:46](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L46)
|
||||
[src/core/structures/sern-emitter.ts:46](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L46)
|
||||
|
||||
___
|
||||
|
||||
### setMaxListeners
|
||||
|
||||
▸ **setMaxListeners**(`n?`, `...eventTargets`): `void`
|
||||
▸ `Static` **setMaxListeners**(`n?`, `...eventTargets`): `void`
|
||||
|
||||
```js
|
||||
const {
|
||||
@@ -1211,6 +1147,10 @@ const emitter = new EventEmitter();
|
||||
setMaxListeners(5, target, emitter);
|
||||
```
|
||||
|
||||
**`Since`**
|
||||
|
||||
v15.4.0
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type | Description |
|
||||
@@ -1222,23 +1162,19 @@ setMaxListeners(5, target, emitter);
|
||||
|
||||
`void`
|
||||
|
||||
**`Since`**
|
||||
|
||||
v15.4.0
|
||||
|
||||
#### Inherited from
|
||||
|
||||
EventEmitter.setMaxListeners
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/@types/node/events.d.ts:346
|
||||
node_modules/@types/node/events.d.ts:317
|
||||
|
||||
___
|
||||
|
||||
### success
|
||||
|
||||
▸ **success**(`module`): `Object`
|
||||
▸ `Static` **success**(`module`): `Object`
|
||||
|
||||
Creates a compliant SernEmitter module success payload
|
||||
|
||||
@@ -1252,20 +1188,15 @@ Creates a compliant SernEmitter module success payload
|
||||
|
||||
`Object`
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `module` | `AnyModule` |
|
||||
| `type` | [`Success`](../enums/PayloadType.md#success) |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:72](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L72)
|
||||
[src/core/structures/sern-emitter.ts:72](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L72)
|
||||
|
||||
___
|
||||
|
||||
### warning
|
||||
|
||||
▸ **warning**(`reason`): `Object`
|
||||
▸ `Static` **warning**(`reason`): `Object`
|
||||
|
||||
Creates a compliant SernEmitter module warning payload
|
||||
|
||||
@@ -1279,11 +1210,6 @@ Creates a compliant SernEmitter module warning payload
|
||||
|
||||
`Object`
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `reason` | `string` |
|
||||
| `type` | [`Warning`](../enums/PayloadType.md#warning) |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/sern-emitter.ts:82](https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L82)
|
||||
[src/core/structures/sern-emitter.ts:82](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/sern-emitter.ts#L82)
|
||||
|
||||
@@ -32,7 +32,7 @@ export default commandModule({
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:20](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L20)
|
||||
[src/core/structures/enums.ts:20](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L20)
|
||||
|
||||
___
|
||||
|
||||
@@ -42,7 +42,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:23](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L23)
|
||||
[src/core/structures/enums.ts:23](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L23)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:29](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L29)
|
||||
[src/core/structures/enums.ts:29](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L29)
|
||||
|
||||
___
|
||||
|
||||
@@ -62,7 +62,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:22](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L22)
|
||||
[src/core/structures/enums.ts:22](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L22)
|
||||
|
||||
___
|
||||
|
||||
@@ -72,7 +72,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:21](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L21)
|
||||
[src/core/structures/enums.ts:21](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L21)
|
||||
|
||||
___
|
||||
|
||||
@@ -82,7 +82,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:28](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L28)
|
||||
[src/core/structures/enums.ts:28](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L28)
|
||||
|
||||
___
|
||||
|
||||
@@ -92,7 +92,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:25](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L25)
|
||||
[src/core/structures/enums.ts:25](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L25)
|
||||
|
||||
___
|
||||
|
||||
@@ -102,7 +102,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:27](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L27)
|
||||
[src/core/structures/enums.ts:27](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L27)
|
||||
|
||||
___
|
||||
|
||||
@@ -112,7 +112,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:19](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L19)
|
||||
[src/core/structures/enums.ts:19](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L19)
|
||||
|
||||
___
|
||||
|
||||
@@ -122,7 +122,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:24](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L24)
|
||||
[src/core/structures/enums.ts:24](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L24)
|
||||
|
||||
___
|
||||
|
||||
@@ -132,7 +132,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:18](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L18)
|
||||
[src/core/structures/enums.ts:18](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L18)
|
||||
|
||||
___
|
||||
|
||||
@@ -142,4 +142,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:26](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L26)
|
||||
[src/core/structures/enums.ts:26](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L26)
|
||||
|
||||
@@ -31,7 +31,7 @@ The EventType for handling discord events
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:51](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L51)
|
||||
[src/core/structures/enums.ts:51](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L51)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,7 +44,7 @@ Could be for example, `process` events, database events
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:60](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L60)
|
||||
[src/core/structures/enums.ts:60](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L60)
|
||||
|
||||
___
|
||||
|
||||
@@ -56,4 +56,4 @@ The EventType for handling sern events
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:55](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L55)
|
||||
[src/core/structures/enums.ts:55](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L55)
|
||||
|
||||
@@ -16,7 +16,7 @@ The PayloadType for a SernEmitter failure event
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:98](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L98)
|
||||
[src/core/structures/enums.ts:98](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L98)
|
||||
|
||||
___
|
||||
|
||||
@@ -28,7 +28,7 @@ The PayloadType for a SernEmitter success event
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:94](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L94)
|
||||
[src/core/structures/enums.ts:94](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L94)
|
||||
|
||||
___
|
||||
|
||||
@@ -40,4 +40,4 @@ The PayloadType for a SernEmitter warning event
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:102](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L102)
|
||||
[src/core/structures/enums.ts:102](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L102)
|
||||
|
||||
@@ -30,7 +30,7 @@ The PluginType for EventPlugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:85](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L85)
|
||||
[src/core/structures/enums.ts:85](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L85)
|
||||
|
||||
___
|
||||
|
||||
@@ -42,4 +42,4 @@ The PluginType for InitPlugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/enums.ts:81](https://github.com/sern-handler/handler/blob/2106522/src/core/structures/enums.ts#L81)
|
||||
[src/core/structures/enums.ts:81](https://github.com/sern-handler/handler/blob/81cdde2/src/core/structures/enums.ts#L81)
|
||||
|
||||
@@ -26,17 +26,30 @@ custom_edit_url: null
|
||||
- For you. A framework that's tailored to your exact needs.
|
||||
- Lightweight. Does a lot while being small.
|
||||
- Latest features. Support for discord.js v14 and all of its interactions.
|
||||
- Hybrid, customizable and composable commands. Create them just how you like.
|
||||
- Start quickly. Plug and play or customize to your liking.
|
||||
- works with [bun](https://bun.sh/) and [node](https://nodejs.org/en) out the box!
|
||||
- Embraces reactive programming. For consistent and reliable backend.
|
||||
- Switch and customize how errors are handled, logging, and more.
|
||||
- Use it with TypeScript or JavaScript. CommonJS and ESM supported.
|
||||
- Active and growing community, always here to help. [Join us](https://sern.dev/discord)
|
||||
- Unleash its full potential with a powerful CLI and awesome plugins.
|
||||
|
||||
## 📜 Installation
|
||||
[Start here!!](https://sern.dev/docs/guide/walkthrough/new-project)
|
||||
|
||||
```sh
|
||||
npm install @sern/handler
|
||||
```
|
||||
|
||||
```sh
|
||||
yarn add @sern/handler
|
||||
```
|
||||
|
||||
```sh
|
||||
pnpm add @sern/handler
|
||||
```
|
||||
|
||||
## 👶 Basic Usage
|
||||
<details><summary>ping.ts</summary>
|
||||
<details open><summary>ping.ts</summary>
|
||||
|
||||
```ts
|
||||
export default commandModule({
|
||||
@@ -50,6 +63,55 @@ export default commandModule({
|
||||
});
|
||||
```
|
||||
</details>
|
||||
<details open><summary>modal.ts</summary>
|
||||
|
||||
```ts
|
||||
export default commandModule({
|
||||
type: CommandType.Modal,
|
||||
//Installed a plugin to make sure modal fields pass a validation.
|
||||
plugins : [
|
||||
assertFields({
|
||||
fields: {
|
||||
name: /^([^0-9]*)$/
|
||||
},
|
||||
failure: (errors, modal) => modal.reply('your submission did not pass the validations')
|
||||
})
|
||||
],
|
||||
execute : (modal) => {
|
||||
modal.reply('thanks for the submission!');
|
||||
}
|
||||
})
|
||||
```
|
||||
</details>
|
||||
<details open><summary>index.ts</summary>
|
||||
|
||||
```ts
|
||||
import { Client, GatewayIntentBits } from 'discord.js';
|
||||
import { Sern, single, type Dependencies } from '@sern/handler';
|
||||
|
||||
//client has been declared previously
|
||||
|
||||
interface MyDependencies extends Dependencies {
|
||||
'@sern/client': Singleton<Client>;
|
||||
}
|
||||
export const useContainer = Sern.makeDependencies<MyDependencies>({
|
||||
build: root => root
|
||||
.add({ '@sern/client': single(() => client) })
|
||||
});
|
||||
|
||||
//View docs for all options
|
||||
Sern.init({
|
||||
defaultPrefix: '!', // removing defaultPrefix will shut down text commands
|
||||
commands: 'src/commands',
|
||||
// events: 'src/events' (optional),
|
||||
containerConfig : {
|
||||
get: useContainer
|
||||
}
|
||||
});
|
||||
|
||||
client.login("YOUR_BOT_TOKEN_HERE");
|
||||
```
|
||||
</details>
|
||||
|
||||
## 🤖 Bots Using sern
|
||||
- [Community Bot](https://github.com/sern-handler/sern-community), the community bot for our [discord server](https://sern.dev/discord).
|
||||
@@ -59,8 +121,7 @@ export default commandModule({
|
||||
- [Murayama](https://github.com/murayamabot/murayama), :pepega:
|
||||
- [Protector (WIP)](https://github.com/needhamgary/Protector), Just a simple bot to help enhance a private minecraft server.
|
||||
- [SmokinWeed 💨](https://github.com/Peter-MJ-Parker/sern-bud), A fun bot for a small - but growing - server.
|
||||
- [Man Nomic](https://github.com/jacoobes/man-nomic), A simple information bot to provide information to the nomic-ai discord community.
|
||||
- [Linear-Discord](https://github.com/sern-handler/linear-discord) Display and manage a linear dashboard.
|
||||
|
||||
## 💻 CLI
|
||||
|
||||
It is **highly encouraged** to use the [command line interface](https://github.com/sern-handler/cli) for your project. Don't forget to view it.
|
||||
|
||||
@@ -20,7 +20,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:125](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L125)
|
||||
[src/types/core-modules.ts:124](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L124)
|
||||
|
||||
___
|
||||
|
||||
@@ -34,7 +34,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:126](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L126)
|
||||
[src/types/core-modules.ts:125](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L125)
|
||||
|
||||
___
|
||||
|
||||
@@ -63,7 +63,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:128](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L128)
|
||||
[src/types/core-modules.ts:127](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L127)
|
||||
|
||||
___
|
||||
|
||||
@@ -77,7 +77,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -91,7 +91,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -101,7 +101,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:127](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L127)
|
||||
[src/types/core-modules.ts:126](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L126)
|
||||
|
||||
___
|
||||
|
||||
@@ -115,7 +115,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -129,4 +129,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:124](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L124)
|
||||
[src/types/core-modules.ts:123](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L123)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:65](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L65)
|
||||
[src/types/core-modules.ts:64](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L64)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:64](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L64)
|
||||
[src/types/core-modules.ts:63](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L63)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:75](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L75)
|
||||
[src/types/core-modules.ts:74](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L74)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:74](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L74)
|
||||
[src/types/core-modules.ts:73](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L73)
|
||||
|
||||
@@ -1,45 +0,0 @@
|
||||
---
|
||||
id: "CommandError.Response"
|
||||
title: "Interface: Response"
|
||||
sidebar_label: "Response"
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
[CommandError](../namespaces/CommandError.md).Response
|
||||
|
||||
## Properties
|
||||
|
||||
### body
|
||||
|
||||
• `Optional` **body**: `ReplyOptions`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/command-error.ts:6](https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L6)
|
||||
|
||||
___
|
||||
|
||||
### log
|
||||
|
||||
• `Optional` **log**: `Object`
|
||||
|
||||
#### Type declaration
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `message` | `unknown` |
|
||||
| `type` | keyof [`Logging`](Logging.md)<`unknown`\> |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/command-error.ts:7](https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L7)
|
||||
|
||||
___
|
||||
|
||||
### type
|
||||
|
||||
• **type**: ``"fail"`` \| ``"continue"``
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/command-error.ts:5](https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L5)
|
||||
@@ -14,7 +14,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:150](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L150)
|
||||
[src/types/core-modules.ts:149](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L149)
|
||||
|
||||
___
|
||||
|
||||
@@ -24,7 +24,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:158](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L158)
|
||||
[src/types/core-modules.ts:157](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L157)
|
||||
|
||||
___
|
||||
|
||||
@@ -34,7 +34,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:160](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L160)
|
||||
[src/types/core-modules.ts:159](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L159)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,7 +44,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:155](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L155)
|
||||
[src/types/core-modules.ts:154](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L154)
|
||||
|
||||
___
|
||||
|
||||
@@ -54,7 +54,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:151](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L151)
|
||||
[src/types/core-modules.ts:150](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L150)
|
||||
|
||||
___
|
||||
|
||||
@@ -64,7 +64,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:157](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L157)
|
||||
[src/types/core-modules.ts:156](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L156)
|
||||
|
||||
___
|
||||
|
||||
@@ -74,7 +74,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:152](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L152)
|
||||
[src/types/core-modules.ts:151](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L151)
|
||||
|
||||
___
|
||||
|
||||
@@ -84,7 +84,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:156](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L156)
|
||||
[src/types/core-modules.ts:155](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L155)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:154](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L154)
|
||||
[src/types/core-modules.ts:153](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L153)
|
||||
|
||||
___
|
||||
|
||||
@@ -104,7 +104,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:159](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L159)
|
||||
[src/types/core-modules.ts:158](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L158)
|
||||
|
||||
___
|
||||
|
||||
@@ -114,7 +114,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:161](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L161)
|
||||
[src/types/core-modules.ts:160](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L160)
|
||||
|
||||
___
|
||||
|
||||
@@ -124,4 +124,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:153](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L153)
|
||||
[src/types/core-modules.ts:152](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L152)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:60](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L60)
|
||||
[src/types/core-modules.ts:59](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L59)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:59](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L59)
|
||||
[src/types/core-modules.ts:58](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L58)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:55](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L55)
|
||||
[src/types/core-modules.ts:54](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L54)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:54](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L54)
|
||||
[src/types/core-modules.ts:53](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L53)
|
||||
|
||||
@@ -34,7 +34,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:73](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L73)
|
||||
[src/types/core-plugin.ts:73](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L73)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,4 +44,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:72](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L72)
|
||||
[src/types/core-plugin.ts:72](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L72)
|
||||
|
||||
@@ -22,7 +22,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:59](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L59)
|
||||
[src/types/core-plugin.ts:59](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L59)
|
||||
|
||||
___
|
||||
|
||||
@@ -40,4 +40,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:60](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L60)
|
||||
[src/types/core-plugin.ts:60](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L60)
|
||||
|
||||
@@ -22,7 +22,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:28](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L28)
|
||||
[src/types/ioc.ts:28](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L28)
|
||||
|
||||
___
|
||||
|
||||
@@ -40,7 +40,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:29](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L29)
|
||||
[src/types/ioc.ts:30](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L30)
|
||||
|
||||
___
|
||||
|
||||
@@ -58,7 +58,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L36)
|
||||
[src/types/ioc.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -76,7 +76,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:37](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L37)
|
||||
[src/types/ioc.ts:29](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L29)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L35)
|
||||
[src/types/ioc.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -110,10 +110,6 @@ ___
|
||||
|
||||
[`CoreModuleStore`](CoreModuleStore.md)
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
Will be removed and turned internal
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L34)
|
||||
[src/types/ioc.ts:31](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L31)
|
||||
|
||||
@@ -8,15 +8,19 @@ custom_edit_url: null
|
||||
|
||||
Represents a core module store that stores IDs mapped to file paths.
|
||||
|
||||
## Implemented by
|
||||
|
||||
- [`ModuleStore`](../classes/ModuleStore.md)
|
||||
|
||||
## Properties
|
||||
|
||||
### commands
|
||||
|
||||
• **commands**: `Map`<`string`, `Module`\>
|
||||
• **commands**: `Map`<`string`, `string`\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-store.ts:7](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-store.ts#L7)
|
||||
[src/core/contracts/module-store.ts:7](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-store.ts#L7)
|
||||
|
||||
___
|
||||
|
||||
@@ -26,4 +30,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-store.ts:8](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-store.ts#L8)
|
||||
[src/core/contracts/module-store.ts:8](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-store.ts#L8)
|
||||
|
||||
@@ -30,7 +30,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,7 +44,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:106](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L106)
|
||||
[src/types/core-modules.ts:105](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L105)
|
||||
|
||||
___
|
||||
|
||||
@@ -58,7 +58,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -72,7 +72,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -86,7 +86,7 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:107](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L107)
|
||||
[src/types/core-modules.ts:106](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L106)
|
||||
|
||||
## Methods
|
||||
|
||||
@@ -110,4 +110,4 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:108](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L108)
|
||||
[src/types/core-modules.ts:107](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L107)
|
||||
|
||||
@@ -1,24 +0,0 @@
|
||||
---
|
||||
id: "Disposable"
|
||||
title: "Interface: Disposable"
|
||||
sidebar_label: "Disposable"
|
||||
sidebar_position: 0
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
Represents a Disposable contract.
|
||||
Let dependencies implement this to dispose and cleanup.
|
||||
|
||||
## Methods
|
||||
|
||||
### dispose
|
||||
|
||||
▸ **dispose**(): `unknown`
|
||||
|
||||
#### Returns
|
||||
|
||||
`unknown`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/hooks.ts:15](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/hooks.ts#L15)
|
||||
@@ -25,7 +25,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/emitter.ts:6](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/emitter.ts#L6)
|
||||
[src/core/contracts/emitter.ts:4](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/emitter.ts#L4)
|
||||
|
||||
___
|
||||
|
||||
@@ -46,7 +46,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/emitter.ts:8](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/emitter.ts#L8)
|
||||
[src/core/contracts/emitter.ts:6](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/emitter.ts#L6)
|
||||
|
||||
___
|
||||
|
||||
@@ -67,4 +67,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/emitter.ts:7](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/emitter.ts#L7)
|
||||
[src/core/contracts/emitter.ts:5](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/emitter.ts#L5)
|
||||
|
||||
@@ -14,12 +14,28 @@ custom_edit_url: null
|
||||
|
||||
- [`DefaultErrorHandling`](../classes/DefaultErrorHandling.md)
|
||||
|
||||
## Properties
|
||||
|
||||
### keepAlive
|
||||
|
||||
• **keepAlive**: `number`
|
||||
|
||||
Number of times the process should throw an error until crashing and exiting
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/error-handling.ts:8](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/error-handling.ts#L8)
|
||||
|
||||
## Methods
|
||||
|
||||
### crash
|
||||
|
||||
▸ **crash**(`err`): `never`
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
Version 4 will remove this method
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -30,13 +46,9 @@ custom_edit_url: null
|
||||
|
||||
`never`
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
Version 4 will remove this method
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/error-handling.ts:9](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/error-handling.ts#L9)
|
||||
[src/core/contracts/error-handling.ts:14](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/error-handling.ts#L14)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,7 +56,8 @@ ___
|
||||
|
||||
▸ **updateAlive**(`error`): `void`
|
||||
|
||||
A function that is called on every throw.
|
||||
A function that is called on every crash. Updates keepAlive.
|
||||
If keepAlive is 0, the process crashes.
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -58,4 +71,4 @@ A function that is called on every throw.
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/error-handling.ts:14](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/error-handling.ts#L14)
|
||||
[src/core/contracts/error-handling.ts:20](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/error-handling.ts#L20)
|
||||
|
||||
@@ -14,7 +14,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:166](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L166)
|
||||
[src/types/core-modules.ts:165](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L165)
|
||||
|
||||
___
|
||||
|
||||
@@ -24,7 +24,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:165](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L165)
|
||||
[src/types/core-modules.ts:164](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L164)
|
||||
|
||||
___
|
||||
|
||||
@@ -34,4 +34,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:167](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L167)
|
||||
[src/types/core-modules.ts:166](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L166)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -34,7 +34,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:48](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L48)
|
||||
[src/types/core-modules.ts:47](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L47)
|
||||
|
||||
___
|
||||
|
||||
@@ -48,7 +48,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:47](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L47)
|
||||
[src/types/core-modules.ts:46](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L46)
|
||||
|
||||
___
|
||||
|
||||
@@ -62,7 +62,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -76,7 +76,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -90,7 +90,7 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:49](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L49)
|
||||
[src/types/core-modules.ts:48](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L48)
|
||||
|
||||
## Methods
|
||||
|
||||
@@ -114,4 +114,4 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:50](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L50)
|
||||
[src/types/core-modules.ts:49](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L49)
|
||||
|
||||
@@ -21,4 +21,4 @@ Let dependencies implement this to initiate some logic.
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/hooks.ts:7](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/hooks.ts#L7)
|
||||
[src/core/contracts/init.ts:8](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/init.ts#L8)
|
||||
|
||||
@@ -34,7 +34,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:69](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L69)
|
||||
[src/types/core-plugin.ts:69](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L69)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,4 +44,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:68](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L68)
|
||||
[src/types/core-plugin.ts:68](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L68)
|
||||
|
||||
@@ -38,7 +38,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/logging.ts:8](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/logging.ts#L8)
|
||||
[src/core/contracts/logging.ts:8](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/logging.ts#L8)
|
||||
|
||||
___
|
||||
|
||||
@@ -58,7 +58,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/logging.ts:5](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/logging.ts#L5)
|
||||
[src/core/contracts/logging.ts:5](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/logging.ts#L5)
|
||||
|
||||
___
|
||||
|
||||
@@ -78,7 +78,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/logging.ts:7](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/logging.ts#L7)
|
||||
[src/core/contracts/logging.ts:7](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/logging.ts#L7)
|
||||
|
||||
___
|
||||
|
||||
@@ -98,4 +98,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/logging.ts:6](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/logging.ts#L6)
|
||||
[src/core/contracts/logging.ts:6](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/logging.ts#L6)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:85](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L85)
|
||||
[src/types/core-modules.ts:84](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L84)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:84](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L84)
|
||||
[src/types/core-modules.ts:83](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L83)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:95](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L95)
|
||||
[src/types/core-modules.ts:94](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L94)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:94](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L94)
|
||||
[src/types/core-modules.ts:93](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L93)
|
||||
|
||||
@@ -9,13 +9,6 @@ custom_edit_url: null
|
||||
**`Since`**
|
||||
|
||||
2.0.0
|
||||
- direct access to the module manager will be removed in version 4
|
||||
|
||||
## Hierarchy
|
||||
|
||||
- `MetadataAccess`
|
||||
|
||||
↳ **`ModuleManager`**
|
||||
|
||||
## Implemented by
|
||||
|
||||
@@ -25,7 +18,7 @@ custom_edit_url: null
|
||||
|
||||
### get
|
||||
|
||||
▸ **get**(`id`): `undefined` \| `Module`
|
||||
▸ **get**(`id`): `undefined` \| `string`
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -35,17 +28,17 @@ custom_edit_url: null
|
||||
|
||||
#### Returns
|
||||
|
||||
`undefined` \| `Module`
|
||||
`undefined` \| `string`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-manager.ts:19](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-manager.ts#L19)
|
||||
[src/core/contracts/module-manager.ts:13](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-manager.ts#L13)
|
||||
|
||||
___
|
||||
|
||||
### getByNameCommandType
|
||||
|
||||
▸ **getByNameCommandType**<`T`\>(`name`, `commandType`): `undefined` \| [`CommandModuleDefs`](CommandModuleDefs.md)[`T`]
|
||||
▸ **getByNameCommandType**<`T`\>(`name`, `commandType`): `undefined` \| `Promise`<[`CommandModuleDefs`](CommandModuleDefs.md)[`T`]\>
|
||||
|
||||
#### Type parameters
|
||||
|
||||
@@ -62,11 +55,11 @@ ___
|
||||
|
||||
#### Returns
|
||||
|
||||
`undefined` \| [`CommandModuleDefs`](CommandModuleDefs.md)[`T`]
|
||||
`undefined` \| `Promise`<[`CommandModuleDefs`](CommandModuleDefs.md)[`T`]\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-manager.ts:30](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-manager.ts#L30)
|
||||
[src/core/contracts/module-manager.ts:18](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-manager.ts#L18)
|
||||
|
||||
___
|
||||
|
||||
@@ -84,29 +77,23 @@ ___
|
||||
|
||||
`undefined` \| `CommandMeta`
|
||||
|
||||
#### Inherited from
|
||||
|
||||
MetadataAccess.getMetadata
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-manager.ts:10](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-manager.ts#L10)
|
||||
[src/core/contracts/module-manager.ts:14](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-manager.ts#L14)
|
||||
|
||||
___
|
||||
|
||||
### getPublishableCommands
|
||||
|
||||
▸ **getPublishableCommands**(): [`CommandModule`](../modules.md#commandmodule)[]
|
||||
▸ **getPublishableCommands**(): `Promise`<[`CommandModule`](../modules.md#commandmodule)[]\>
|
||||
|
||||
#### Returns
|
||||
|
||||
[`CommandModule`](../modules.md#commandmodule)[]
|
||||
|
||||
**`Deprecated`**
|
||||
`Promise`<[`CommandModule`](../modules.md#commandmodule)[]\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-manager.ts:25](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-manager.ts#L25)
|
||||
[src/core/contracts/module-manager.ts:17](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-manager.ts#L17)
|
||||
|
||||
___
|
||||
|
||||
@@ -119,7 +106,7 @@ ___
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `id` | `string` |
|
||||
| `path` | `Module` |
|
||||
| `path` | `string` |
|
||||
|
||||
#### Returns
|
||||
|
||||
@@ -127,7 +114,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-manager.ts:21](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-manager.ts#L21)
|
||||
[src/core/contracts/module-manager.ts:16](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-manager.ts#L16)
|
||||
|
||||
___
|
||||
|
||||
@@ -146,10 +133,6 @@ ___
|
||||
|
||||
`void`
|
||||
|
||||
#### Inherited from
|
||||
|
||||
MetadataAccess.setMetadata
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/module-manager.ts:11](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/module-manager.ts#L11)
|
||||
[src/core/contracts/module-manager.ts:15](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/module-manager.ts#L15)
|
||||
|
||||
@@ -34,7 +34,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:64](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L64)
|
||||
[src/types/core-plugin.ts:64](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L64)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,4 +44,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:63](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L63)
|
||||
[src/types/core-plugin.ts:63](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L63)
|
||||
|
||||
@@ -1,82 +0,0 @@
|
||||
---
|
||||
id: "Presence.Result"
|
||||
title: "Interface: Result"
|
||||
sidebar_label: "Result"
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
[Presence](../namespaces/Presence.md).Result
|
||||
|
||||
## Properties
|
||||
|
||||
### activities
|
||||
|
||||
• `Optional` **activities**: `ActivitiesOptions`[]
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:11](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L11)
|
||||
|
||||
___
|
||||
|
||||
### afk
|
||||
|
||||
• `Optional` **afk**: `boolean`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:10](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L10)
|
||||
|
||||
___
|
||||
|
||||
### onRepeat
|
||||
|
||||
• `Optional` **onRepeat**: (`previous`: [`Result`](Presence.Result.md)) => [`Result`](Presence.Result.md)
|
||||
|
||||
#### Type declaration
|
||||
|
||||
▸ (`previous`): [`Result`](Presence.Result.md)
|
||||
|
||||
##### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `previous` | [`Result`](Presence.Result.md) |
|
||||
|
||||
##### Returns
|
||||
|
||||
[`Result`](Presence.Result.md)
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:14](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L14)
|
||||
|
||||
___
|
||||
|
||||
### repeat
|
||||
|
||||
• `Optional` **repeat**: `number` \| [[`Emitter`](Emitter.md), `string`]
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:13](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L13)
|
||||
|
||||
___
|
||||
|
||||
### shardId
|
||||
|
||||
• `Optional` **shardId**: `number`[]
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:12](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L12)
|
||||
|
||||
___
|
||||
|
||||
### status
|
||||
|
||||
• `Optional` **status**: `Status`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:9](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L9)
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:80](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L80)
|
||||
[src/types/core-modules.ts:79](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L79)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:79](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L79)
|
||||
[src/types/core-modules.ts:78](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L78)
|
||||
|
||||
@@ -20,7 +20,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:172](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L172)
|
||||
[src/types/core-modules.ts:171](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L171)
|
||||
|
||||
___
|
||||
|
||||
@@ -30,7 +30,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:177](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L177)
|
||||
[src/types/core-modules.ts:176](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L176)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,7 +44,7 @@ Omit.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4493
|
||||
node_modules/discord.js/typings/index.d.ts:4301
|
||||
|
||||
___
|
||||
|
||||
@@ -58,7 +58,7 @@ Omit.descriptionLocalizations
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4494
|
||||
node_modules/discord.js/typings/index.d.ts:4302
|
||||
|
||||
___
|
||||
|
||||
@@ -72,7 +72,7 @@ Omit.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4491
|
||||
node_modules/discord.js/typings/index.d.ts:4299
|
||||
|
||||
___
|
||||
|
||||
@@ -86,7 +86,7 @@ Omit.nameLocalizations
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4492
|
||||
node_modules/discord.js/typings/index.d.ts:4300
|
||||
|
||||
___
|
||||
|
||||
@@ -100,7 +100,7 @@ Omit.required
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4495
|
||||
node_modules/discord.js/typings/index.d.ts:4303
|
||||
|
||||
___
|
||||
|
||||
@@ -110,4 +110,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:173](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L173)
|
||||
[src/types/core-modules.ts:172](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L172)
|
||||
|
||||
@@ -30,7 +30,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,7 +44,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:42](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L42)
|
||||
[src/types/core-modules.ts:41](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L41)
|
||||
|
||||
___
|
||||
|
||||
@@ -58,7 +58,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -72,7 +72,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -86,7 +86,7 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:43](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L43)
|
||||
[src/types/core-modules.ts:42](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L42)
|
||||
|
||||
## Methods
|
||||
|
||||
@@ -110,4 +110,4 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:44](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L44)
|
||||
[src/types/core-modules.ts:43](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L43)
|
||||
|
||||
@@ -14,7 +14,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:21](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L21)
|
||||
[src/types/utility.ts:21](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L21)
|
||||
|
||||
___
|
||||
|
||||
@@ -24,7 +24,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:20](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L20)
|
||||
[src/types/utility.ts:20](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L20)
|
||||
|
||||
___
|
||||
|
||||
@@ -34,7 +34,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:19](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L19)
|
||||
[src/types/utility.ts:19](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L19)
|
||||
|
||||
___
|
||||
|
||||
@@ -44,7 +44,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:23](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L23)
|
||||
[src/types/utility.ts:23](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L23)
|
||||
|
||||
___
|
||||
|
||||
@@ -54,4 +54,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:22](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L22)
|
||||
[src/types/utility.ts:22](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L22)
|
||||
|
||||
@@ -76,7 +76,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:209](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L209)
|
||||
[src/types/core-modules.ts:208](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L208)
|
||||
|
||||
___
|
||||
|
||||
@@ -104,4 +104,4 @@ APIApplicationCommandOptionBase.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:208](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L208)
|
||||
[src/types/core-modules.ts:207](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L207)
|
||||
|
||||
@@ -24,7 +24,7 @@ BaseApplicationCommandOptionsData.autocomplete
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4496
|
||||
node_modules/discord.js/typings/index.d.ts:4304
|
||||
|
||||
___
|
||||
|
||||
@@ -38,7 +38,7 @@ BaseApplicationCommandOptionsData.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4493
|
||||
node_modules/discord.js/typings/index.d.ts:4301
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ BaseApplicationCommandOptionsData.descriptionLocalizations
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4494
|
||||
node_modules/discord.js/typings/index.d.ts:4302
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ BaseApplicationCommandOptionsData.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4491
|
||||
node_modules/discord.js/typings/index.d.ts:4299
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ BaseApplicationCommandOptionsData.nameLocalizations
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4492
|
||||
node_modules/discord.js/typings/index.d.ts:4300
|
||||
|
||||
___
|
||||
|
||||
@@ -90,7 +90,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:214](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L214)
|
||||
[src/types/core-modules.ts:213](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L213)
|
||||
|
||||
___
|
||||
|
||||
@@ -104,7 +104,7 @@ BaseApplicationCommandOptionsData.required
|
||||
|
||||
#### Defined in
|
||||
|
||||
node_modules/discord.js/typings/index.d.ts:4495
|
||||
node_modules/discord.js/typings/index.d.ts:4303
|
||||
|
||||
___
|
||||
|
||||
@@ -114,4 +114,4 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:213](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L213)
|
||||
[src/types/core-modules.ts:212](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L212)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:118](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L118)
|
||||
[src/types/core-modules.ts:117](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L117)
|
||||
|
||||
___
|
||||
|
||||
@@ -53,7 +53,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:120](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L120)
|
||||
[src/types/core-modules.ts:119](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L119)
|
||||
|
||||
___
|
||||
|
||||
@@ -67,7 +67,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -81,7 +81,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -91,7 +91,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:119](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L119)
|
||||
[src/types/core-modules.ts:118](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L118)
|
||||
|
||||
___
|
||||
|
||||
@@ -105,7 +105,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -119,4 +119,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:117](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L117)
|
||||
[src/types/core-modules.ts:116](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L116)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:70](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L70)
|
||||
[src/types/core-modules.ts:69](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L69)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:69](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L69)
|
||||
[src/types/core-modules.ts:68](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L68)
|
||||
|
||||
@@ -20,7 +20,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:112](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L112)
|
||||
[src/types/core-modules.ts:111](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L111)
|
||||
|
||||
___
|
||||
|
||||
@@ -34,7 +34,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -63,7 +63,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:113](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L113)
|
||||
[src/types/core-modules.ts:112](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L112)
|
||||
|
||||
___
|
||||
|
||||
@@ -77,7 +77,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -91,7 +91,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -105,7 +105,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -119,4 +119,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:111](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L111)
|
||||
[src/types/core-modules.ts:110](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L110)
|
||||
|
||||
@@ -24,7 +24,7 @@ Module.description
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:36](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L36)
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L35)
|
||||
|
||||
___
|
||||
|
||||
@@ -52,7 +52,7 @@ Module.execute
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:90](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L90)
|
||||
[src/types/core-modules.ts:89](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L89)
|
||||
|
||||
___
|
||||
|
||||
@@ -66,7 +66,7 @@ Module.name
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L33)
|
||||
[src/types/core-modules.ts:32](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L32)
|
||||
|
||||
___
|
||||
|
||||
@@ -80,7 +80,7 @@ Module.onEvent
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L34)
|
||||
[src/types/core-modules.ts:33](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L33)
|
||||
|
||||
___
|
||||
|
||||
@@ -94,7 +94,7 @@ Module.plugins
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:35](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L35)
|
||||
[src/types/core-modules.ts:34](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L34)
|
||||
|
||||
___
|
||||
|
||||
@@ -108,4 +108,4 @@ Module.type
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:89](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L89)
|
||||
[src/types/core-modules.ts:88](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L88)
|
||||
|
||||
@@ -14,7 +14,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core.ts:9](https://github.com/sern-handler/handler/blob/2106522/src/types/core.ts#L9)
|
||||
[src/types/core.ts:8](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core.ts#L8)
|
||||
|
||||
___
|
||||
|
||||
@@ -30,7 +30,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core.ts:20](https://github.com/sern-handler/handler/blob/2106522/src/types/core.ts#L20)
|
||||
[src/types/core.ts:18](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core.ts#L18)
|
||||
|
||||
___
|
||||
|
||||
@@ -40,7 +40,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core.ts:10](https://github.com/sern-handler/handler/blob/2106522/src/types/core.ts#L10)
|
||||
[src/types/core.ts:9](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core.ts#L9)
|
||||
|
||||
___
|
||||
|
||||
@@ -50,20 +50,16 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core.ts:11](https://github.com/sern-handler/handler/blob/2106522/src/types/core.ts#L11)
|
||||
[src/types/core.ts:10](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core.ts#L10)
|
||||
|
||||
___
|
||||
|
||||
### mode
|
||||
|
||||
• `Optional` **mode**: `string`
|
||||
• `Optional` **mode**: ``"DEV"`` \| ``"PROD"``
|
||||
|
||||
Overload to enable mode in case developer does not use a .env file.
|
||||
|
||||
**`Deprecated`**
|
||||
|
||||
- https://github.com/sern-handler/handler/pull/325
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core.ts:16](https://github.com/sern-handler/handler/blob/2106522/src/types/core.ts#L16)
|
||||
[src/types/core.ts:14](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core.ts#L14)
|
||||
|
||||
@@ -8,7 +8,6 @@ custom_edit_url: null
|
||||
|
||||
## Namespaces
|
||||
|
||||
- [Presence](namespaces/Presence.md)
|
||||
- [Sern](namespaces/Sern.md)
|
||||
|
||||
## Enumerations
|
||||
@@ -20,11 +19,14 @@ custom_edit_url: null
|
||||
|
||||
## Classes
|
||||
|
||||
- [CommandExecutable](classes/CommandExecutable.md)
|
||||
- [Context](classes/Context.md)
|
||||
- [DefaultErrorHandling](classes/DefaultErrorHandling.md)
|
||||
- [DefaultLogging](classes/DefaultLogging.md)
|
||||
- [DefaultModuleManager](classes/DefaultModuleManager.md)
|
||||
- [EventExecutable](classes/EventExecutable.md)
|
||||
- [ModuleStore](classes/ModuleStore.md)
|
||||
- [SernEmitter](classes/SernEmitter.md)
|
||||
|
||||
## Interfaces
|
||||
|
||||
@@ -39,7 +41,6 @@ custom_edit_url: null
|
||||
- [CoreDependencies](interfaces/CoreDependencies.md)
|
||||
- [CoreModuleStore](interfaces/CoreModuleStore.md)
|
||||
- [DiscordEventCommand](interfaces/DiscordEventCommand.md)
|
||||
- [Disposable](interfaces/Disposable.md)
|
||||
- [Emitter](interfaces/Emitter.md)
|
||||
- [ErrorHandling](interfaces/ErrorHandling.md)
|
||||
- [EventModuleDefs](interfaces/EventModuleDefs.md)
|
||||
@@ -63,6 +64,12 @@ custom_edit_url: null
|
||||
- [UserSelectCommand](interfaces/UserSelectCommand.md)
|
||||
- [Wrapper](interfaces/Wrapper.md)
|
||||
|
||||
## References
|
||||
|
||||
### controller
|
||||
|
||||
Re-exports [controller](namespaces/Sern.md#controller)
|
||||
|
||||
## Type Aliases
|
||||
|
||||
### AnyCommandPlugin
|
||||
@@ -71,7 +78,7 @@ custom_edit_url: null
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:76](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L76)
|
||||
[src/types/core-plugin.ts:76](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L76)
|
||||
|
||||
___
|
||||
|
||||
@@ -81,17 +88,17 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:77](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L77)
|
||||
[src/types/core-plugin.ts:77](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L77)
|
||||
|
||||
___
|
||||
|
||||
### Args
|
||||
|
||||
Ƭ **Args**: `ParseType`<\{ `slash`: [`SlashOptions`](modules.md#slashoptions) ; `text`: `string`[] }\>
|
||||
Ƭ **Args**: `ParseType`<{ `slash`: [`SlashOptions`](modules.md#slashoptions) ; `text`: `string`[] }\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:16](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L16)
|
||||
[src/types/utility.ts:16](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L16)
|
||||
|
||||
___
|
||||
|
||||
@@ -101,7 +108,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:132](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L132)
|
||||
[src/types/core-modules.ts:131](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L131)
|
||||
|
||||
___
|
||||
|
||||
@@ -111,7 +118,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:131](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L131)
|
||||
[src/types/core-modules.ts:130](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L130)
|
||||
|
||||
___
|
||||
|
||||
@@ -130,7 +137,7 @@ If T has an init method, this will be called.
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:17](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L17)
|
||||
[src/types/ioc.ts:17](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L17)
|
||||
|
||||
___
|
||||
|
||||
@@ -152,17 +159,17 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/contracts/logging.ts:11](https://github.com/sern-handler/handler/blob/2106522/src/core/contracts/logging.ts#L11)
|
||||
[src/core/contracts/logging.ts:11](https://github.com/sern-handler/handler/blob/81cdde2/src/core/contracts/logging.ts#L11)
|
||||
|
||||
___
|
||||
|
||||
### Payload
|
||||
|
||||
Ƭ **Payload**: \{ `module`: `AnyModule` ; `type`: [`Success`](enums/PayloadType.md#success) } \| \{ `module?`: `AnyModule` ; `reason`: `string` \| `Error` ; `type`: [`Failure`](enums/PayloadType.md#failure) } \| \{ `reason`: `string` ; `type`: [`Warning`](enums/PayloadType.md#warning) }
|
||||
Ƭ **Payload**: { `module`: `AnyModule` ; `type`: [`Success`](enums/PayloadType.md#success) } \| { `module?`: `AnyModule` ; `reason`: `string` \| `Error` ; `type`: [`Failure`](enums/PayloadType.md#failure) } \| { `reason`: `string` ; `type`: [`Warning`](enums/PayloadType.md#warning) }
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:26](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L26)
|
||||
[src/types/utility.ts:26](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L26)
|
||||
|
||||
___
|
||||
|
||||
@@ -172,7 +179,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-plugin.ts:51](https://github.com/sern-handler/handler/blob/2106522/src/types/core-plugin.ts#L51)
|
||||
[src/types/core-plugin.ts:51](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-plugin.ts#L51)
|
||||
|
||||
___
|
||||
|
||||
@@ -184,7 +191,7 @@ Type that replaces autocomplete with [SernAutocompleteData](interfaces/SernAutoc
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/core-modules.ts:200](https://github.com/sern-handler/handler/blob/2106522/src/types/core-modules.ts#L200)
|
||||
[src/types/core-modules.ts:199](https://github.com/sern-handler/handler/blob/81cdde2/src/types/core-modules.ts#L199)
|
||||
|
||||
___
|
||||
|
||||
@@ -211,7 +218,7 @@ T is created once and lazily.
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:7](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L7)
|
||||
[src/types/ioc.ts:7](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L7)
|
||||
|
||||
___
|
||||
|
||||
@@ -221,7 +228,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/utility.ts:14](https://github.com/sern-handler/handler/blob/2106522/src/types/utility.ts#L14)
|
||||
[src/types/utility.ts:14](https://github.com/sern-handler/handler/blob/81cdde2/src/types/utility.ts#L14)
|
||||
|
||||
___
|
||||
|
||||
@@ -254,29 +261,7 @@ Every time this is called, a new object is created
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/types/ioc.ts:12](https://github.com/sern-handler/handler/blob/2106522/src/types/ioc.ts#L12)
|
||||
|
||||
## Variables
|
||||
|
||||
### controller
|
||||
|
||||
• `Const` **controller**: `Object`
|
||||
|
||||
**`Since`**
|
||||
|
||||
1.0.0
|
||||
The object passed into every plugin to control a command's behavior
|
||||
|
||||
#### Type declaration
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `next` | () => `OkImpl`<`void`\> |
|
||||
| `stop` | () => `ErrImpl`<`void`\> |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/create-plugins.ts:69](https://github.com/sern-handler/handler/blob/2106522/src/core/create-plugins.ts#L69)
|
||||
[src/types/ioc.ts:12](https://github.com/sern-handler/handler/blob/81cdde2/src/types/ioc.ts#L12)
|
||||
|
||||
## Functions
|
||||
|
||||
@@ -284,6 +269,11 @@ The object passed into every plugin to control a command's behavior
|
||||
|
||||
▸ **CommandControlPlugin**<`I`\>(`execute`): [`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -300,14 +290,9 @@ The object passed into every plugin to control a command's behavior
|
||||
|
||||
[`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/create-plugins.ts:37](https://github.com/sern-handler/handler/blob/2106522/src/core/create-plugins.ts#L37)
|
||||
[src/core/create-plugins.ts:36](https://github.com/sern-handler/handler/blob/81cdde2/src/core/create-plugins.ts#L36)
|
||||
|
||||
___
|
||||
|
||||
@@ -315,6 +300,11 @@ ___
|
||||
|
||||
▸ **CommandInitPlugin**<`I`\>(`execute`): [`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -331,14 +321,9 @@ ___
|
||||
|
||||
[`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/create-plugins.ts:28](https://github.com/sern-handler/handler/blob/2106522/src/core/create-plugins.ts#L28)
|
||||
[src/core/create-plugins.ts:27](https://github.com/sern-handler/handler/blob/81cdde2/src/core/create-plugins.ts#L27)
|
||||
|
||||
___
|
||||
|
||||
@@ -346,6 +331,15 @@ ___
|
||||
|
||||
▸ **DiscordEventControlPlugin**<`T`\>(`name`, `execute`): [`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
|
||||
**`Experimental`**
|
||||
|
||||
A specialized function for creating control plugins with discord.js ClientEvents.
|
||||
Will probably be moved one day!
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -363,18 +357,9 @@ ___
|
||||
|
||||
[`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
|
||||
**`Experimental`**
|
||||
|
||||
A specialized function for creating control plugins with discord.js ClientEvents.
|
||||
Will probably be moved one day!
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/create-plugins.ts:58](https://github.com/sern-handler/handler/blob/2106522/src/core/create-plugins.ts#L58)
|
||||
[src/core/create-plugins.ts:57](https://github.com/sern-handler/handler/blob/81cdde2/src/core/create-plugins.ts#L57)
|
||||
|
||||
___
|
||||
|
||||
@@ -382,6 +367,11 @@ ___
|
||||
|
||||
▸ **EventControlPlugin**<`I`\>(`execute`): [`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -398,14 +388,9 @@ ___
|
||||
|
||||
[`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/create-plugins.ts:46](https://github.com/sern-handler/handler/blob/2106522/src/core/create-plugins.ts#L46)
|
||||
[src/core/create-plugins.ts:45](https://github.com/sern-handler/handler/blob/81cdde2/src/core/create-plugins.ts#L45)
|
||||
|
||||
___
|
||||
|
||||
@@ -413,6 +398,11 @@ ___
|
||||
|
||||
▸ **EventInitPlugin**<`I`\>(`execute`): [`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -429,14 +419,9 @@ ___
|
||||
|
||||
[`Plugin`](interfaces/Plugin.md)<`unknown`[]\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.5.0
|
||||
@__PURE__
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/create-plugins.ts:19](https://github.com/sern-handler/handler/blob/2106522/src/core/create-plugins.ts#L19)
|
||||
[src/core/create-plugins.ts:18](https://github.com/sern-handler/handler/blob/81cdde2/src/core/create-plugins.ts#L18)
|
||||
|
||||
___
|
||||
|
||||
@@ -447,7 +432,16 @@ ___
|
||||
The new Service api, a cleaner alternative to useContainer
|
||||
To obtain intellisense, ensure a .d.ts file exists in the root of compilation.
|
||||
Usually our scaffolding tool takes care of this.
|
||||
Note: this method only works AFTER your container has been initiated
|
||||
|
||||
**`Since`**
|
||||
|
||||
3.0.0
|
||||
|
||||
**`Example`**
|
||||
|
||||
```ts
|
||||
const client = Service('@sern/client');
|
||||
```
|
||||
|
||||
#### Type parameters
|
||||
|
||||
@@ -465,19 +459,9 @@ Note: this method only works AFTER your container has been initiated
|
||||
|
||||
`NonNullable`<`UnpackFunction`<`Partial`<`Dependencies`\>[`T`]\>\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
3.0.0
|
||||
|
||||
**`Example`**
|
||||
|
||||
```ts
|
||||
const client = Service('@sern/client');
|
||||
```
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/ioc/dependency-injection.ts:37](https://github.com/sern-handler/handler/blob/2106522/src/core/ioc/dependency-injection.ts#L37)
|
||||
[src/core/ioc/dependency-injection.ts:37](https://github.com/sern-handler/handler/blob/81cdde2/src/core/ioc/dependency-injection.ts#L37)
|
||||
|
||||
___
|
||||
|
||||
@@ -485,6 +469,11 @@ ___
|
||||
|
||||
▸ **Services**<`T`\>(`...keys`): `IntoDependencies`<`T`\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
3.0.0
|
||||
The plural version of [Service](modules.md#service)
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -503,14 +492,9 @@ ___
|
||||
|
||||
array of dependencies, in the same order of keys provided
|
||||
|
||||
**`Since`**
|
||||
|
||||
3.0.0
|
||||
The plural version of [Service](modules.md#service)
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/ioc/dependency-injection.ts:47](https://github.com/sern-handler/handler/blob/2106522/src/core/ioc/dependency-injection.ts#L47)
|
||||
[src/core/ioc/dependency-injection.ts:45](https://github.com/sern-handler/handler/blob/81cdde2/src/core/ioc/dependency-injection.ts#L45)
|
||||
|
||||
___
|
||||
|
||||
@@ -518,6 +502,10 @@ ___
|
||||
|
||||
▸ **commandModule**(`mod`): [`CommandModule`](modules.md#commandmodule)
|
||||
|
||||
**`Since`**
|
||||
|
||||
1.0.0 The wrapper function to define command modules for sern
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -528,13 +516,9 @@ ___
|
||||
|
||||
[`CommandModule`](modules.md#commandmodule)
|
||||
|
||||
**`Since`**
|
||||
|
||||
1.0.0 The wrapper function to define command modules for sern
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:19](https://github.com/sern-handler/handler/blob/2106522/src/core/modules.ts#L19)
|
||||
[src/core/modules.ts:25](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L25)
|
||||
|
||||
___
|
||||
|
||||
@@ -546,6 +530,8 @@ Create event modules from discord.js client events,
|
||||
This is an [eventModule](modules.md#eventmodule-1) for discord events,
|
||||
where typings can be very bad.
|
||||
|
||||
**`Experimental`**
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -565,11 +551,9 @@ where typings can be very bad.
|
||||
|
||||
[`EventModule`](modules.md#eventmodule)
|
||||
|
||||
**`Experimental`**
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:47](https://github.com/sern-handler/handler/blob/2106522/src/core/modules.ts#L47)
|
||||
[src/core/modules.ts:53](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L53)
|
||||
|
||||
___
|
||||
|
||||
@@ -577,6 +561,11 @@ ___
|
||||
|
||||
▸ **eventModule**(`mod`): [`EventModule`](modules.md#eventmodule)
|
||||
|
||||
**`Since`**
|
||||
|
||||
1.0.0
|
||||
The wrapper function to define event modules for sern
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -587,14 +576,9 @@ ___
|
||||
|
||||
[`EventModule`](modules.md#eventmodule)
|
||||
|
||||
**`Since`**
|
||||
|
||||
1.0.0
|
||||
The wrapper function to define event modules for sern
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/modules.ts:32](https://github.com/sern-handler/handler/blob/2106522/src/core/modules.ts#L32)
|
||||
[src/core/modules.ts:38](https://github.com/sern-handler/handler/blob/81cdde2/src/core/modules.ts#L38)
|
||||
|
||||
___
|
||||
|
||||
@@ -602,6 +586,10 @@ ___
|
||||
|
||||
▸ **makeDependencies**<`T`\>(`conf`): `Promise`<<V\>(...`keys`: [...V[]]) => `IntoDependencies`<`V`\>\>
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.0.0
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
@@ -610,9 +598,9 @@ ___
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `conf` | `ValidDependencyConfig` |
|
||||
| Name | Type | Description |
|
||||
| :------ | :------ | :------ |
|
||||
| `conf` | `DependencyConfiguration` | a configuration for creating your project dependencies |
|
||||
|
||||
#### Returns
|
||||
|
||||
@@ -620,7 +608,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/ioc/base.ts:144](https://github.com/sern-handler/handler/blob/2106522/src/core/ioc/base.ts#L144)
|
||||
[src/core/ioc/base.ts:25](https://github.com/sern-handler/handler/blob/81cdde2/src/core/ioc/base.ts#L25)
|
||||
|
||||
___
|
||||
|
||||
@@ -647,7 +635,7 @@ ___
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/create-plugins.ts:6](https://github.com/sern-handler/handler/blob/2106522/src/core/create-plugins.ts#L6)
|
||||
[src/core/create-plugins.ts:5](https://github.com/sern-handler/handler/blob/81cdde2/src/core/create-plugins.ts#L5)
|
||||
|
||||
___
|
||||
|
||||
@@ -657,6 +645,11 @@ ___
|
||||
|
||||
@__PURE__
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.0.0.
|
||||
Creates a singleton object.
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name |
|
||||
@@ -679,14 +672,9 @@ ___
|
||||
|
||||
`T`
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.0.0.
|
||||
Creates a singleton object.
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/ioc/dependency-injection.ts:11](https://github.com/sern-handler/handler/blob/2106522/src/core/ioc/dependency-injection.ts#L11)
|
||||
[src/core/ioc/dependency-injection.ts:12](https://github.com/sern-handler/handler/blob/81cdde2/src/core/ioc/dependency-injection.ts#L12)
|
||||
|
||||
___
|
||||
|
||||
@@ -696,6 +684,11 @@ ___
|
||||
|
||||
@__PURE__
|
||||
|
||||
**`Since`**
|
||||
|
||||
2.0.0
|
||||
Creates a transient object
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name |
|
||||
@@ -724,11 +717,23 @@ ___
|
||||
|
||||
`T`
|
||||
|
||||
**`Since`**
|
||||
#### Defined in
|
||||
|
||||
2.0.0
|
||||
Creates a transient object
|
||||
[src/core/ioc/dependency-injection.ts:22](https://github.com/sern-handler/handler/blob/81cdde2/src/core/ioc/dependency-injection.ts#L22)
|
||||
|
||||
___
|
||||
|
||||
### useContainerRaw
|
||||
|
||||
▸ **useContainerRaw**(): `CoreContainer`<`Partial`<`Dependencies`\>\>
|
||||
|
||||
Returns the underlying data structure holding all dependencies.
|
||||
Exposes methods from iti
|
||||
|
||||
#### Returns
|
||||
|
||||
`CoreContainer`<`Partial`<`Dependencies`\>\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/ioc/dependency-injection.ts:21](https://github.com/sern-handler/handler/blob/2106522/src/core/ioc/dependency-injection.ts#L21)
|
||||
[src/core/ioc/base.ts:13](https://github.com/sern-handler/handler/blob/81cdde2/src/core/ioc/base.ts#L13)
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
---
|
||||
id: "CommandError"
|
||||
title: "Namespace: CommandError"
|
||||
sidebar_label: "CommandError"
|
||||
sidebar_position: 0
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
## Interfaces
|
||||
|
||||
- [Response](../interfaces/CommandError.Response.md)
|
||||
|
||||
## Functions
|
||||
|
||||
### of
|
||||
|
||||
▸ **of**(): `Object`
|
||||
|
||||
#### Returns
|
||||
|
||||
`Object`
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `log` | <T\>(`type`: keyof [`Logging`](../interfaces/Logging.md)<`unknown`\>, `message`: `T`) => `Record`<`PropertyKey`, `unknown`\> |
|
||||
| `reply` | (`bodyContent`: `ReplyOptions`) => `Record`<`PropertyKey`, `unknown`\> |
|
||||
| `status` | (`p`: ``"fail"`` \| ``"continue"``) => `Record`<`PropertyKey`, `unknown`\> |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/structures/command-error.ts:10](https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L10)
|
||||
@@ -1,93 +0,0 @@
|
||||
---
|
||||
id: "Presence"
|
||||
title: "Namespace: Presence"
|
||||
sidebar_label: "Presence"
|
||||
sidebar_position: 0
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
## Interfaces
|
||||
|
||||
- [Result](../interfaces/Presence.Result.md)
|
||||
|
||||
## Type Aliases
|
||||
|
||||
### Config
|
||||
|
||||
Ƭ **Config**<`T`\>: `Object`
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `T` | extends keyof `Dependencies`[] |
|
||||
|
||||
#### Type declaration
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `execute` | (...`v`: `IntoDependencies`<`T`\>) => [`Result`](../interfaces/Presence.Result.md) |
|
||||
| `inject?` | [...T] |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:17](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L17)
|
||||
|
||||
## Functions
|
||||
|
||||
### module
|
||||
|
||||
▸ **module**<`T`\>(`conf`): [`Config`](Presence.md#config)<`T`\>
|
||||
|
||||
A small wrapper to provide type inference.
|
||||
Create a Presence module which **MUST** be put in a file called presence.(language-extension)
|
||||
adjacent to the file where **Sern.init** is CALLED.
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `T` | extends keyof `Dependencies`[] |
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `conf` | [`Config`](Presence.md#config)<`T`\> |
|
||||
|
||||
#### Returns
|
||||
|
||||
[`Config`](Presence.md#config)<`T`\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:28](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L28)
|
||||
|
||||
___
|
||||
|
||||
### of
|
||||
|
||||
▸ **of**(`root`): `Object`
|
||||
|
||||
Create a Presence body which can be either:
|
||||
- once, the presence is activated only once.
|
||||
- repeated, per cycle or event, the presence can be changed.
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `root` | `Omit`<[`Result`](../interfaces/Presence.Result.md), ``"repeat"`` \| ``"onRepeat"``\> |
|
||||
|
||||
#### Returns
|
||||
|
||||
`Object`
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `once` | () => `Omit`<[`Result`](../interfaces/Presence.Result.md), ``"repeat"`` \| ``"onRepeat"``\> |
|
||||
| `repeated` | (`onRepeat`: `PresenceReduce`, `repeat`: `number` \| [[`Emitter`](../interfaces/Emitter.md), `string`]) => \{ `activities?`: `ActivitiesOptions`[] ; `afk?`: `boolean` ; `onRepeat`: `PresenceReduce` ; `repeat`: `number` \| [[`Emitter`](../interfaces/Emitter.md), `string`] ; `shardId?`: `number`[] ; `status?`: `Status` } |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/core/presences.ts:37](https://github.com/sern-handler/handler/blob/2106522/src/core/presences.ts#L37)
|
||||
@@ -6,22 +6,34 @@ sidebar_position: 0
|
||||
custom_edit_url: null
|
||||
---
|
||||
|
||||
## Variables
|
||||
|
||||
### controller
|
||||
|
||||
• `Const` **controller**: `Object`
|
||||
|
||||
**`Since`**
|
||||
|
||||
1.0.0
|
||||
The object passed into every plugin to control a command's behavior
|
||||
|
||||
#### Type declaration
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `next` | () => `OkImpl`<`void`\> |
|
||||
| `stop` | () => `ErrImpl`<`void`\> |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/sern.ts:72](https://github.com/sern-handler/handler/blob/81cdde2/src/sern.ts#L72)
|
||||
|
||||
## Functions
|
||||
|
||||
### init
|
||||
|
||||
▸ **init**(`maybeWrapper`): `void`
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `maybeWrapper` | [`Wrapper`](../interfaces/Wrapper.md) \| ``"file"`` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`void`
|
||||
|
||||
**`Since`**
|
||||
|
||||
1.0.0
|
||||
@@ -35,6 +47,16 @@ Sern.init({
|
||||
})
|
||||
```
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `maybeWrapper` | [`Wrapper`](../interfaces/Wrapper.md) \| ``"file"`` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`void`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[src/sern.ts:26](https://github.com/sern-handler/handler/blob/2106522/src/sern.ts#L26)
|
||||
[src/sern.ts:24](https://github.com/sern-handler/handler/blob/81cdde2/src/sern.ts#L24)
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
# CLI
|
||||
|
||||
Publish commands to the API, install plugins, and use other tools provided by our cli.
|
||||
|
||||
The CLI is your pocketknife for discord bot development. It'll have all features necessary for developing and shipping to production.
|
||||
```
|
||||
Usage: sern [options] [command]
|
||||
|
||||
|
||||
___ ___ _ __ _ __
|
||||
/ __|/ _ \ '__| '_ \
|
||||
\__ \ __/ | | | | |
|
||||
|___/\___|_| |_| |_|
|
||||
|
||||
Welcome!
|
||||
If you're new to sern, run npm create @sern/bot for an interactive setup to your new bot project!
|
||||
|
||||
If you have any ideas, suggestions, bug reports, kindly join our support server: https://sern.dev/discord
|
||||
|
||||
Options:
|
||||
-v, --version output the version number
|
||||
-h, --help display help for command
|
||||
|
||||
Commands:
|
||||
init [options] Quickest way to scaffold a new project [DEPRECATED]
|
||||
plugins [options] Install plugins from https://github.com/sern-handler/awesome-plugins
|
||||
extra Easy way to add extra things in your sern project
|
||||
commands Defacto way to manage your slash commands
|
||||
help [command] display help for command
|
||||
```
|
||||
@@ -1,211 +0,0 @@
|
||||
```sh
|
||||
Usage: sern build [options]
|
||||
|
||||
Build your bot
|
||||
|
||||
Options:
|
||||
-f --format [fmt] The module system of your application. `cjs` or `esm` (default: "esm")
|
||||
-m --mode [mode] the mode for sern to build in. `production` or `development` (default: "development")
|
||||
-W --suppress-warnings suppress experimental warning
|
||||
-p --project [filePath] build with this sern.build file
|
||||
-h, --help display help for command
|
||||
```
|
||||
|
||||
## Guiding Principles
|
||||
|
||||
When designing the `sern build` command, our aim was to make building bot applications as simple as possible for the majority of developers. The setup process has been streamlined, and most of the configuration details have been handled for you. Here are some key points to keep in mind:
|
||||
|
||||
1. **Minimal Configuration**: In the vast majority (99%) of use cases, developers do not need to configure the bot application building process. We believe that simplicity is key, so only a few decisions need to be made on the developer's end.
|
||||
|
||||
2. **Optimal Defaults**: We've chosen sensible defaults. This means you can get started without getting bogged down by complex, unneeded configurations.
|
||||
|
||||
3. **Finetuned for production bots**: Our CLI leverages an opinionated build solution powered by esbuild. This ensures that bots are built without issues and can be shipped easily.
|
||||
|
||||
## Experimental Features
|
||||
|
||||
Both the `sern build` and `sern publish` commands are marked as experimental. While they might not be completely stable, they are designed to work for the majority of users. We appreciate any feedback in helping us make these features even better.
|
||||
|
||||
## Features
|
||||
|
||||
The `sern build` command comes equipped with a range of features designed to enhance your development process. Here's a glimpse of what it offers:
|
||||
|
||||
- **esbuild Integration**: our CLI takes inspiration from the efficiency of SvelteKit, ensuring your bot application is built effectively and with type safety. Leverage the [esbuild plugin ecosystem](https://github.com/esbuild/community-plugins).
|
||||
|
||||
- **Zero Configuration**: Building your bot application without additional configuration. The CLI handles most of the setup for you.
|
||||
|
||||
- **Experimental Image Support**: We've introduced experimental support for top-level imports of PNG and JPG files, making it easier to include images in your bot application.
|
||||
|
||||
- **Compile Time Constants**: Customize your build with constants such as \_\_DEV\_\_, \_\_PROD\_\_, allowing you to tailor your application to different production stages.
|
||||
|
||||
- **Development and Production Modes**: The CLI supports both development and production modes, enabling you to tailor your bot application for different stages of development.
|
||||
|
||||
|
||||
- **Type-safe `process.env`**: The CLI generates a type-safe `process.env`, reducing potential errors.
|
||||
## Implicits
|
||||
- command line arguments take precendence over sern.build configuration file
|
||||
- default build format is ESM
|
||||
- defineVersion = true
|
||||
- __DEV__ AND __PROD__ constants are configured.
|
||||
- only a [few tsconfig options](https://esbuild.github.io/content-types/#tsconfig-json) are respected.
|
||||
### sern.build.js
|
||||
- For any extra configuration you may need
|
||||
- the cli was intentionally made to be installed globally, and we can't provide typings at a project level. If you need typings, here they are:
|
||||
```ts
|
||||
type BuildOptions = {
|
||||
/**
|
||||
* Define __VERSION__
|
||||
* This option is a quick switch to defining the __VERSION__ constant which will be a string of the version provided in
|
||||
* cwd's package.json
|
||||
*/
|
||||
defineVersion?: boolean
|
||||
/**
|
||||
* default = esm
|
||||
*/
|
||||
format?: 'cjs' | 'esm'
|
||||
/**
|
||||
* extra esbuild plugins to build with sern.
|
||||
*/
|
||||
esbuildPlugins?: esbuild.Plugin[]
|
||||
/**
|
||||
* https://esbuild.github.io/api/#drop-labels
|
||||
**/
|
||||
dropLabels?: string[]
|
||||
/**
|
||||
* https://esbuild.github.io/api/#define
|
||||
**/
|
||||
define?: Record<string, string>
|
||||
/**
|
||||
* Path to tsconfig
|
||||
**/
|
||||
tsconfig?: string;
|
||||
/**
|
||||
* default = 'development'
|
||||
*/
|
||||
mode: 'production' | 'development',
|
||||
/**
|
||||
* will search for env file. If none exists,
|
||||
* default to .env.
|
||||
*/
|
||||
env?: string
|
||||
}
|
||||
```
|
||||
|
||||
## Usage
|
||||
```
|
||||
sern build
|
||||
```
|
||||
(that was easy)
|
||||
|
||||
## Adapting older projects
|
||||
- Change your tsconfig.json to extend our generated one.
|
||||
|
||||
```json
|
||||
{
|
||||
// highlight-start
|
||||
"extends": "./.sern/tsconfig.json",
|
||||
// highlight-end
|
||||
"compilerOptions" : {
|
||||
//all of your old fields
|
||||
}
|
||||
}
|
||||
```
|
||||
## In depth
|
||||
We use the `define` and `drop labels` api in C style macros to have easy development stage differences.
|
||||
[Here](https://esbuild.github.io/api/#drop-labels) is the esbuild full API documentation
|
||||
### drop labels
|
||||
|
||||
```sh
|
||||
# mode is set to production
|
||||
sern build
|
||||
```
|
||||
|
||||
|
||||
import Tabs from '@theme/Tabs';
|
||||
import TabItem from '@theme/TabItem';
|
||||
|
||||
<Tabs>
|
||||
<TabItem value="input" label="Input">
|
||||
|
||||
```ts
|
||||
__DEV__: console.log('This is for production only')
|
||||
__PROD__: console.log('This is for either mode')
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
<TabItem value="sh" label="Running build for production">
|
||||
|
||||
```sh
|
||||
# mode is set to production
|
||||
sern build
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
|
||||
<TabItem value="output" label="Output">
|
||||
|
||||
```ts
|
||||
__PROD__ console.log('This is for either mode')
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
</Tabs>
|
||||
|
||||
### constants
|
||||
sern builds with three default constants. \_\_DEV\_\_, \_\_PROD\_\_, \_\_VERSION\_\_.
|
||||
|
||||
<Tabs>
|
||||
|
||||
<TabItem value="input" label="Preprocess">
|
||||
|
||||
```sh
|
||||
sern build
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
<TabItem value="sh" label="Constants available and typesafe!">
|
||||
|
||||
```ts
|
||||
if(__PROD__) {
|
||||
console.log('Bot version: ' + __VERSION__)
|
||||
}
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
</Tabs>
|
||||
|
||||
Full esbuild documentation [here](https://esbuild.github.io/api/#define)
|
||||
Add more to the `define` field in build options (only availible with a `sern.build` file at the moment.
|
||||
|
||||
### process.env
|
||||
We generate your process.env with `dotenv` and generate typings for process.env. Less hassle!
|
||||
|
||||
<Tabs>
|
||||
|
||||
<TabItem value="input" label=".env">
|
||||
|
||||
```sh
|
||||
DISCORD_TOKEN=<your token>
|
||||
```
|
||||
```ts
|
||||
process.env.DISCORD_TOKEN // string | undefined (not typesafe :()
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
<TabItem value="sh" label="sern build">
|
||||
|
||||
```sh
|
||||
sern build
|
||||
```
|
||||
```ts
|
||||
process.env.DISCORD_TOKEN // string (typesafe :))
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
</Tabs>
|
||||
@@ -1,28 +0,0 @@
|
||||
```sh
|
||||
Usage: sern commands clear [options]
|
||||
|
||||
Clear and reset commands-data-remote.json and the api
|
||||
|
||||
Options:
|
||||
-y, --yes Say yes to all prompts
|
||||
-e, --env [path] Supply a path to a .env
|
||||
-h, --help display help for command
|
||||
```
|
||||
## Implicits
|
||||
- Automatically reads a .env in the working directory. For seamless integration, your .env file should look like this:
|
||||
```txt title=".env"
|
||||
DISCORD_TOKEN=<YOUR_TOKEN>
|
||||
APPLICATION_ID=<YOUR_APPLICATION_ID>
|
||||
NODE_ENV=<development|production>
|
||||
```
|
||||
- Calls the discord API with the [PUT route](https://discord.com/developers/docs/interactions/application-commands#bulk-overwrite-global-application-commands) with an EMPTY array, essentially setting all registered commands to nothing.
|
||||
|
||||
- Optionally override an .env path as a command line argument as well. **CLI arguments take precedence.**
|
||||
If you do not know how to obtain either of these credentials, [click here](https://github.com/reactiflux/discord-irc/wiki/Creating-a-discord-bot-&-getting-a-token)
|
||||
|
||||
- Automatically confirm with the **-y** flag.
|
||||
|
||||
## Features
|
||||
- Clears all application data and sern-commands-data.json
|
||||
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
|
||||
```sh
|
||||
Usage: sern extra [options]
|
||||
|
||||
Easy way to add extra things in your sern project
|
||||
|
||||
Options:
|
||||
-h, --help display help for command
|
||||
```
|
||||
|
||||
This command is pretty straightfoward. Install utilities into your application. Assumes you have a sern.config.json.
|
||||
@@ -1,102 +0,0 @@
|
||||
```sh
|
||||
Usage: sern commands publish [options] [path]
|
||||
|
||||
New way to manage your slash commands
|
||||
|
||||
Arguments:
|
||||
path path with respect to current working directory that will locate all published files
|
||||
|
||||
Options:
|
||||
-i, --import [scriptPath...] Prerequire a script to load into publisher
|
||||
-t, --token [token]
|
||||
--appId [applicationId]
|
||||
-h, --help display help for command
|
||||
```
|
||||
## Implicits
|
||||
- Automatically reads a .env in the working directory. For seamless integration, your .env file should look like this:
|
||||
```txt title=".env"
|
||||
DISCORD_TOKEN=<YOUR_TOKEN>
|
||||
APPLICATION_ID=<YOUR_APPLICATION_ID>
|
||||
NODE_ENV=<production|development>
|
||||
```
|
||||
- Calls the discord API with the [PUT route](https://discord.com/developers/docs/interactions/application-commands#bulk-overwrite-global-application-commands). Wherever your commands directory is located, publish will override the existing application commands at Discord. Existing commands do not count towards the command limit creation daily.
|
||||
|
||||
You may pass these in as command line arguments as well. **CLI arguments take precedence.**
|
||||
If you do not know how to obtain either of these credentials, [click here](https://github.com/reactiflux/discord-irc/wiki/Creating-a-discord-bot-&-getting-a-token)
|
||||
|
||||
## Usage
|
||||
|
||||

|
||||
|
||||
|
||||
## Features
|
||||
- Automatically syncs api with your command base
|
||||
- generates JSON file of output (**.sern/command-data-remote.json**)
|
||||
- supports publishing direct esm typescript files
|
||||
- commonjs + javascript users need to compile first and then run sern publish on the dist/ output
|
||||
- prerequire scripts.
|
||||
- supports a configuration that is the same as the original publish plugin.
|
||||
|
||||
|
||||
Each command file can have an extra config that follows `ValidPublishOptions`:
|
||||
## Config
|
||||
```ts
|
||||
|
||||
type ValidMemberPermissions =
|
||||
| PermissionFlagBits //discord.js enum
|
||||
| PermissionFlagBits[] //array of discord.js enum
|
||||
| string //must be a stringified number
|
||||
| bigint
|
||||
|
||||
interface PublishConfig {
|
||||
guildIds?: string[];
|
||||
dmPermission?: boolean;
|
||||
defaultMemberPermissions: ValidMemberPermissions;
|
||||
}
|
||||
type ValidPublishOptions =
|
||||
| PublishConfig
|
||||
| (absPath: string, module: CommandModule) => PublishConfig
|
||||
```
|
||||
In other words, you can export a function or object.
|
||||
|
||||
## Prerequiring
|
||||
Is there a [service](../guide/walkthrough/services) that is required at the top level of a command?
|
||||
- Create an ES6 script anywhere:
|
||||
|
||||
```ts title="scripts/prerequire.mjs"
|
||||
import { makeDependencies, single, Service } from '@sern/handler'
|
||||
import { Client } from 'discord.js'
|
||||
|
||||
await makeDependencies({
|
||||
build: (root) =>
|
||||
root.add({ "@sern/client": single(() => new Client(...options)) }),
|
||||
});
|
||||
|
||||
await Service('@sern/client').login()
|
||||
```
|
||||
This will create a container for publishing. (as of 0.6.0, client is required or this will crash)
|
||||
|
||||
### Example: command published in guild
|
||||
|
||||
#### Script ran:
|
||||
```
|
||||
sern commands publish -i ./scripts/prerequire.mjs
|
||||
```
|
||||
```ts title=src/commands/ping.ts
|
||||
import { commandModule, Service, CommandType } from '@sern/handler'
|
||||
|
||||
const client = Service('@sern/client');
|
||||
|
||||
export const config = {
|
||||
guildIds: ["889026545715400705"]
|
||||
}
|
||||
|
||||
export default commandModule( {
|
||||
type: CommandType.Slash
|
||||
description: `${client.user.username}'s ping`,
|
||||
execute: (ctx) => {
|
||||
ctx.reply('pong')
|
||||
}
|
||||
})
|
||||
|
||||
```
|
||||
@@ -1 +0,0 @@
|
||||
label: Getting Started
|
||||
@@ -1 +0,0 @@
|
||||
label: Walkthrough
|
||||
@@ -20,7 +20,6 @@ sern plugins
|
||||
Make sure to have a correct [sern.config.json](./good-to-know.md#sernconfigjson)
|
||||
:::
|
||||
|
||||
|
||||
This will display a menu selection of all installable plugins. <br />
|
||||
|
||||
**Note**: You must have a [sern.config.json](good-to-know.md) to use this command.
|
||||
@@ -31,4 +30,3 @@ If you want to view plugins, visit the repository linked above.
|
||||
sern extra
|
||||
```
|
||||
|
||||
We have a more in depth [guide](../../cli/README.md) of the CLI
|
||||
|
||||
@@ -1,11 +1,8 @@
|
||||
---
|
||||
sidebar_position: 7
|
||||
---
|
||||
|
||||
# Dependency Injection
|
||||
|
||||
:::warning
|
||||
This contains version 2 code. Please view [transitioning to v3](./transition)
|
||||
This contains version 2 code. Please view [transitioning to v3](../transition)
|
||||
:::
|
||||
|
||||
Since version 2.0.0, dependency injection, thanks to [iti](https://github.com/molszanski/iti), is a feature to customize your bot's utilities and structures.
|
||||
|
||||
@@ -4,9 +4,21 @@ sidebar_position: 1
|
||||
|
||||
# Create a new project
|
||||
|
||||
```sh
|
||||
npm install -g @sern/cli
|
||||
```
|
||||
Running this will install our CLI. (you'll probably want to download this)
|
||||
- helps manage your applications
|
||||
- plugs you into the sern ecosystem.
|
||||
|
||||
|
||||
|
||||
### Create a new bot
|
||||
|
||||
```sh
|
||||
npm create @sern/bot
|
||||
```
|
||||
and follow the interactive prompts.
|
||||
|
||||
if somehow you need help, feel free to ask [here](https://sern.dev/discord)
|
||||
if somehow you need help, feel free to ask [here](https://sern.dev.discord)
|
||||
|
||||
|
||||
@@ -2,12 +2,11 @@
|
||||
sidebar_position: 6
|
||||
---
|
||||
|
||||
# Services
|
||||
|
||||
:::tip
|
||||
This is version 3 api only!!
|
||||
:::
|
||||
|
||||
# Services
|
||||
|
||||
:::tip
|
||||
TLDR: The direct upgrade to useContainer. if you set up a bot with create-bot, check dependencies.d.ts.
|
||||
@@ -47,110 +46,16 @@ export default commandModule({
|
||||
}
|
||||
//
|
||||
})
|
||||
|
||||
```
|
||||
|
||||
|
||||
import Tabs from '@theme/Tabs';
|
||||
import TabItem from '@theme/TabItem';
|
||||
|
||||
|
||||
## Safety
|
||||
- Services cannot be called in other services while makeDependencies is forming.
|
||||
|
||||
<Tabs>
|
||||
|
||||
<TabItem value="good" label="A good example">
|
||||
|
||||
Lets pass a logger into our database.
|
||||
```ts title="index.ts" showLineNumbers
|
||||
await makeDependencies({
|
||||
build: root => root
|
||||
//Overriding the default logger provided.
|
||||
.upsert({ '@sern/logger': single(() => new Logger()) })
|
||||
|
||||
// Wiring our logger into the database.
|
||||
.add(ctx => {
|
||||
return { database: single(() => new Database(ctx['sern/logger']))) }
|
||||
})
|
||||
})
|
||||
```
|
||||
</TabItem>
|
||||
|
||||
<TabItem value="bad" label="Don't do this">
|
||||
|
||||
```ts title="index.ts" showLineNumbers
|
||||
await makeDependencies({
|
||||
build: root => root
|
||||
//Overriding the default logger provided.
|
||||
.upsert({ '@sern/logger': single(() => new Logger()) })
|
||||
|
||||
// Wiring our logger into the database.
|
||||
// We wire our database incorrectly. Logger should be passed INTO the constructor
|
||||
.add({ database: single(() => new Database()) })
|
||||
})
|
||||
```
|
||||
|
||||
```ts title="index.ts" showLineNumbers
|
||||
import { Service, makeDependencies } from '@sern/handler';
|
||||
|
||||
//Calling Service prematurely!
|
||||
const logger = Service('@sern/logger');
|
||||
|
||||
class Database {
|
||||
|
||||
constructor() {
|
||||
this.logger = logger
|
||||
}
|
||||
}
|
||||
```
|
||||
This is a code smell anyway. It breaks encapsulation and defeats the purpose of wiring dependencies
|
||||
</TabItem>
|
||||
</Tabs>
|
||||
|
||||
## Safety
|
||||
- Services can only be used after sern has made dependencies.
|
||||
- Calling a service before will crash your application.
|
||||
- Services can be safely used outside of commandModules.
|
||||
- Services can be safely used outside of commandModules.
|
||||
- Be careful to not cause too many side effects.
|
||||
|
||||
|
||||
|
||||
- You will need to wire dependencies together.
|
||||
|
||||
<Tabs>
|
||||
<TabItem value="good" label="A good example">
|
||||
|
||||
```ts title="index.ts" showLineNumbers
|
||||
await makeDependencies(...pass your options here)
|
||||
```
|
||||
```ts title="commands/ping.ts" showLineNumbers
|
||||
// This is guaranteed to be defined if configured correctly
|
||||
import { Service } from '@sern/handler';
|
||||
const client = Service('@sern/client');
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
<TabItem value="bad" label="Don't do this">
|
||||
|
||||
```ts title="index.ts" showLineNumbers
|
||||
import { Service, makeDependencies } from '@sern/handler';
|
||||
/* DON'T USE SERVICES BEFORE CALLING makeDependencies */
|
||||
const logger = Service('@sern/logger');
|
||||
|
||||
await makeDependencies()
|
||||
```
|
||||
|
||||
</TabItem>
|
||||
|
||||
</Tabs>
|
||||
|
||||
- Services can only be used after sern has made dependencies.
|
||||
- Calling a service before will crash your application.
|
||||
- Services can be safely used outside of commandModules.
|
||||
- Be careful to not cause too many side effects.
|
||||
|
||||
|
||||
## Related api
|
||||
## Related api
|
||||
- use `Service` for single dependency.
|
||||
- use `Services` for multiple dependencies.
|
||||
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
sidebar_position: 3
|
||||
---
|
||||
|
||||
# Transition from v2 to v3
|
||||
|
||||
# transition from v2 to v3
|
||||
|
||||
```diff title="src/index.ts"
|
||||
- Sern.makeDependencies({ build: () => {} })
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
// @ts-check
|
||||
// Note: type annotations allow type checking and IDEs autocompletion
|
||||
|
||||
// WARNING: When changing things in this file, please also change them on the other docgen.docusaurus.config.js file!
|
||||
const lightCodeTheme = require('prism-react-renderer/themes/nightOwlLight');
|
||||
const darkCodeTheme = require('prism-react-renderer/themes/oceanicNext');
|
||||
|
||||
const lightCodeTheme = require('prism-react-renderer').themes.nightOwlLight;
|
||||
const darkCodeTheme = require('prism-react-renderer').themes.oceanicNext;
|
||||
/** @type {import('@docusaurus/types').Config} */
|
||||
const config = {
|
||||
title: 'sern - Handlers. Redefined.',
|
||||
@@ -27,10 +26,7 @@ const config = {
|
||||
// to replace "en" with "zh-Hans".
|
||||
i18n: {
|
||||
defaultLocale: 'en',
|
||||
locales: ['en']
|
||||
},
|
||||
markdown: {
|
||||
format: 'detect'
|
||||
locales: ['en', 'fr', 'tr'],
|
||||
},
|
||||
presets: [
|
||||
[
|
||||
@@ -48,9 +44,8 @@ const config = {
|
||||
// Remove this to remove the "edit this page" links.
|
||||
editUrl:
|
||||
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
|
||||
blogSidebarCount: 'ALL',
|
||||
},
|
||||
pages: {
|
||||
pages : {
|
||||
path: 'src/pages',
|
||||
routeBasePath: '/',
|
||||
include: ['**/*.{js,jsx,ts,tsx,md,mdx}'],
|
||||
@@ -71,23 +66,22 @@ const config = {
|
||||
themeConfig:
|
||||
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
|
||||
({
|
||||
image: 'https://sern.dev/img/logo.png',
|
||||
algolia: {
|
||||
appId: 'AA9S5J9NYT',
|
||||
apiKey: 'ccfe6abc4d12ac6f882565a9d0caafb1',
|
||||
indexName: 'sern',
|
||||
insights: true,
|
||||
container: 'div',
|
||||
debug: false,
|
||||
contextualSearch: true,
|
||||
externalUrlRegex: 'external\\.com|domain\\.com',
|
||||
replaceSearchResultPathname: {
|
||||
from: '/docs/api',
|
||||
to: '/docs/api',
|
||||
},
|
||||
algolia: {
|
||||
appId: 'AA9S5J9NYT',
|
||||
apiKey: 'ccfe6abc4d12ac6f882565a9d0caafb1',
|
||||
indexName: 'sern',
|
||||
insights: true,
|
||||
container: 'div',
|
||||
debug: false,
|
||||
contextualSearch: true,
|
||||
externalUrlRegex: 'external\\.com|domain\\.com',
|
||||
replaceSearchResultPathname: {
|
||||
from: '/docs/api',
|
||||
to: '/docs/api',
|
||||
},
|
||||
searchParameters: {},
|
||||
searchPagePath: 'search',
|
||||
},
|
||||
},
|
||||
navbar: {
|
||||
title: 'Home',
|
||||
logo: {
|
||||
@@ -101,13 +95,12 @@ const config = {
|
||||
position: 'left',
|
||||
label: 'Docs & Guide',
|
||||
},
|
||||
{ to: '/blog', label: 'Blog', position: 'left' },
|
||||
{to: '/blog', label: 'Blog', position: 'left'},
|
||||
{
|
||||
href: 'https://github.com/sern-handler',
|
||||
label: 'GitHub',
|
||||
position: 'right',
|
||||
},
|
||||
{ to: "/sponsors", label: "Sponsor", position: "left" },
|
||||
{
|
||||
to: '/plugins',
|
||||
label: 'Plugins',
|
||||
@@ -139,7 +132,7 @@ const config = {
|
||||
href: 'https://discord.gg/DwbF5H5JgQ',
|
||||
},
|
||||
{
|
||||
label: 'Open Collective',
|
||||
label : 'Open Collective',
|
||||
href: 'https://opencollective.com/sern'
|
||||
}
|
||||
],
|
||||
@@ -152,7 +145,7 @@ const config = {
|
||||
to: '/blog',
|
||||
},
|
||||
{
|
||||
label: 'GitHub',
|
||||
label: 'GitHub',
|
||||
href: 'https://github.com/sern-handler',
|
||||
},
|
||||
],
|
||||
@@ -160,20 +153,18 @@ const config = {
|
||||
],
|
||||
copyright: `Built with ❤️ by the sern Handler team and its contributors`,
|
||||
},
|
||||
metadata: [
|
||||
metadata : [
|
||||
{ name: 'og:title', content: 'sern - Handlers. Redefined.' },
|
||||
{ name: 'og:description', content: 'A modular, customizable, fast Discord.js framework to streamline bot development' },
|
||||
{ name: 'og:description', content: 'A customizable, batteries-included, powerful discord.js framework to automate and streamline bot development' },
|
||||
{ name: 'og:image', content: 'https://i.imgur.com/rr8nqDP.png' },
|
||||
{ name: 'og:url', content: 'https://sern.dev' },
|
||||
{ name: 'og:type', content: 'website' },
|
||||
{ name: 'twitter:card', content: 'summary_large_image' },
|
||||
{ name: 'twitter:site', content: '@sern-handler' },
|
||||
{ property: 'og:image:alt', content: 'sernlogo' },
|
||||
{ name: 'twitter:title', content: 'sern - Handlers. Redefined.' },
|
||||
{ name: 'twitter:description', content: 'A modular, customizable, fast Discord.js framework to streamline bot development' },
|
||||
{ name: 'keywords', content: 'discord, bot, handler, framework, documentation, sern' },
|
||||
{ name: 'twitter:image', content: 'https://sern.dev/img/logo.png' },
|
||||
{ name: 'twitter:description', content: 'A customizable, batteries-included, powerful discord.js framework to automate and streamline bot development' },
|
||||
{ name: 'twitter:image', content: './assets/images/logo.png' },
|
||||
{ name: 'twitter:url', content: 'https://sern.dev' },
|
||||
{ property: 'og:image:height', content: '512' },
|
||||
{ property: 'og:image:width', content: '1024' },
|
||||
{ name: 'theme-color', content: '#F25186' }
|
||||
],
|
||||
prism: {
|
||||
@@ -181,28 +172,16 @@ const config = {
|
||||
darkTheme: darkCodeTheme,
|
||||
},
|
||||
}),
|
||||
plugins: [
|
||||
/* [
|
||||
'docusaurus-plugin-typedoc',
|
||||
{
|
||||
//if you're editing website, please change this to your local branch of sern to generate documentation
|
||||
entryPoints: ['../sernHandlerV2/src/index.ts'],
|
||||
tsconfig: '../sernHandlerV2/tsconfig.json',
|
||||
},
|
||||
], */
|
||||
[
|
||||
"@dipakparmar/docusaurus-plugin-umami",
|
||||
{
|
||||
websiteID: "e82ff65c-b08f-47b5-8e74-5c31cbcec0ad",
|
||||
analyticsDomain: "analytics.srizan.dev",
|
||||
scriptName: 'ua.js',
|
||||
dataAutoTrack: true,
|
||||
dataDoNotTrack: true,
|
||||
dataCache: true,
|
||||
dataDomains: "sern.dev",
|
||||
},
|
||||
]
|
||||
]
|
||||
// plugins : [
|
||||
// [
|
||||
// 'docusaurus-plugin-typedoc',
|
||||
// {
|
||||
// //if you're editing website, please change this to your local branch of sern to generate documentation
|
||||
// entryPoints: ['../sernHandlerV2/src/index.ts'],
|
||||
// tsconfig: '../sernHandlerV2/tsconfig.json',
|
||||
// },
|
||||
// ]
|
||||
// ]
|
||||
};
|
||||
|
||||
module.exports = config;
|
||||
|
||||
18560
package-lock.json
generated
18560
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
26
package.json
26
package.json
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "sern-website",
|
||||
"name": "@sern/website",
|
||||
"version": "1.0.0",
|
||||
"private": true,
|
||||
"description": "Our modern, clean and beginner friendly web interface",
|
||||
@@ -17,24 +17,22 @@
|
||||
"typedoc-json": "typedoc --json ../sern-community/docs.json --pretty --entryPoints ../sernHandlerV2/src/index.ts --tsconfig ../sernHandlerV2/tsconfig.json --excludeExternals"
|
||||
},
|
||||
"dependencies": {
|
||||
"@dipakparmar/docusaurus-plugin-umami": "^2.1.1",
|
||||
"@docusaurus/core": "3.0.0",
|
||||
"@docusaurus/preset-classic": "3.0.0",
|
||||
"@mdx-js/react": "^3.0.0",
|
||||
"@docusaurus/core": "^2.4.0",
|
||||
"@docusaurus/plugin-content-pages": "^2.4.0",
|
||||
"@docusaurus/preset-classic": "^2.4.0",
|
||||
"@docusaurus/theme-search-algolia": "^2.4.0",
|
||||
"@mdx-js/react": "^1.6.22",
|
||||
"clsx": "^1.2.1",
|
||||
"jsdoc-parse-plus": "^1.3.0",
|
||||
"prism-react-renderer": "^2.1.0",
|
||||
"react": "^18.2.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"react-modal": "^3.16.1"
|
||||
"prism-react-renderer": "^1.3.5",
|
||||
"react": "^17.0.2",
|
||||
"react-dom": "^17.0.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@docusaurus/module-type-aliases": "3.0.0",
|
||||
"@docusaurus/types": "3.0.0",
|
||||
"@docusaurus/module-type-aliases": "2.0.0-rc.1",
|
||||
"docusaurus-plugin-typedoc": "latest",
|
||||
"typedoc": "latest",
|
||||
"typedoc-plugin-markdown": "latest",
|
||||
"typescript": "latest"
|
||||
"typedoc-plugin-markdown": "latest"
|
||||
},
|
||||
"browserslist": {
|
||||
"production": [
|
||||
@@ -49,7 +47,7 @@
|
||||
]
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18.16"
|
||||
"node": ">=16.14"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
import styles from './index.module.css'
|
||||
import PluginModal from "../PluginModal";
|
||||
|
||||
export default function PluginCard({ plugin }) {
|
||||
return (
|
||||
<div className={styles.card}>
|
||||
<div className={styles.cardHeader}>
|
||||
<h3>{plugin.name}</h3>
|
||||
</div>
|
||||
<div className={styles.cardBody}>
|
||||
<p>{plugin.trimmedDescription}</p>
|
||||
</div>
|
||||
<div className={styles.cardFooter}>
|
||||
<PluginModal plugin={plugin} />
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
/*
|
||||
- description
|
||||
- hash
|
||||
- name
|
||||
- author
|
||||
- link
|
||||
- example
|
||||
- version
|
||||
*/
|
||||
@@ -1,32 +0,0 @@
|
||||
.card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
width: 25%;
|
||||
height: 100%;
|
||||
padding: 1rem;
|
||||
border-radius: 0.5rem;
|
||||
background-color: var(--color-white);
|
||||
box-shadow: 0 0 1rem 0 rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.cardHeader {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
.cardBody {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
height: 100%;
|
||||
}
|
||||
.cardFooter {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-top: 1rem;
|
||||
/* put on the right side of the footer */
|
||||
margin-left: auto;
|
||||
}
|
||||
@@ -1,88 +0,0 @@
|
||||
import React from 'react';
|
||||
import Modal from 'react-modal';
|
||||
import styles from "./index.module.css";
|
||||
import CodeBlock from "@theme/CodeBlock";
|
||||
import clsx from "clsx";
|
||||
import useTheme from "../../hooks/useTheme";
|
||||
|
||||
const light = {
|
||||
content: {
|
||||
top: '50%',
|
||||
left: '50%',
|
||||
right: 'auto',
|
||||
bottom: 'auto',
|
||||
marginRight: '-50%',
|
||||
transform: 'translate(-50%, -50%)',
|
||||
width: "70vw",
|
||||
height: "50vh",
|
||||
backgroundColor: "#fff",
|
||||
},
|
||||
};
|
||||
const dark = {
|
||||
content: {
|
||||
top: '50%',
|
||||
left: '50%',
|
||||
right: 'auto',
|
||||
bottom: 'auto',
|
||||
marginRight: '-50%',
|
||||
transform: 'translate(-50%, -50%)',
|
||||
width: "70vw",
|
||||
height: "50vh",
|
||||
backgroundColor: "#333",
|
||||
color: "#fff"
|
||||
},
|
||||
};
|
||||
|
||||
export default function PluginModal({ plugin }) {
|
||||
const [modalIsOpen, setIsOpen] = React.useState(false);
|
||||
const [theme] = useTheme();
|
||||
const [modalCSS, setModalCSS] = React.useState(theme === "dark" ? dark : light);
|
||||
function openModal() {
|
||||
setIsOpen(true);
|
||||
}
|
||||
function closeModal() {
|
||||
setIsOpen(false);
|
||||
}
|
||||
React.useEffect(() => {
|
||||
setModalCSS(theme === "dark" ? dark : light)
|
||||
}, [theme])
|
||||
return (
|
||||
<div>
|
||||
<button onClick={openModal}>Info</button>
|
||||
<Modal
|
||||
isOpen={modalIsOpen}
|
||||
onRequestClose={closeModal}
|
||||
style={modalCSS}
|
||||
contentLabel={plugin.name}
|
||||
>
|
||||
<h2>{plugin.name} by {parseAuthor(plugin.author)}</h2>
|
||||
<p>{plugin.description}</p>
|
||||
<CodeBlock
|
||||
language="ts"
|
||||
title="/src/commands/ping.ts"
|
||||
showLineNumbers
|
||||
>
|
||||
{plugin.example.replace('```ts', '').replace('```', '').trim()}
|
||||
</CodeBlock>
|
||||
<div className={styles.closeButton}>
|
||||
<button onClick={closeModal}>close</button>
|
||||
</div>
|
||||
</Modal>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
function parseAuthor(aut) {
|
||||
const [interestingStuff,] = aut.toString().replace(/[\]<>@]/g, "").split("[")
|
||||
return interestingStuff.trim()
|
||||
}
|
||||
|
||||
/*
|
||||
- description
|
||||
- hash
|
||||
- name
|
||||
- author
|
||||
- link
|
||||
- example
|
||||
- version
|
||||
*/
|
||||
@@ -1,11 +0,0 @@
|
||||
.closeButton {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
padding: 0.5rem;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
[data-theme='dark'] .modal {
|
||||
background-color: var(--ifm-color-primary);
|
||||
}
|
||||
@@ -1,92 +0,0 @@
|
||||
import styles from './styles.module.css';
|
||||
import {useEffect, useState} from "react";
|
||||
|
||||
export default function Sponsors() {
|
||||
const [sponsors, setSponsors] = useState({})
|
||||
useEffect(() => {
|
||||
const asyncFunction = async () => {
|
||||
fetch("https://opencollective.com/api/graphql/v2", {
|
||||
body: JSON.stringify({
|
||||
"operationName": "BannerTopContributors",
|
||||
"variables": {
|
||||
"collectiveSlug": "sern"
|
||||
},
|
||||
"query": "query BannerTopContributors($collectiveSlug: String!) {\n account(slug: $collectiveSlug, throwIfMissing: false) {\n id\n currency\n slug\n ... on AccountWithContributions {\n contributors(limit: 150) {\n totalCount\n nodes {\n id\n name\n roles\n isAdmin\n isCore\n isBacker\n since\n image\n description\n collectiveSlug\n totalAmountDonated\n type\n publicMessage\n isIncognito\n __typename\n }\n __typename\n }\n __typename\n }\n __typename\n }\n}"
|
||||
}),
|
||||
method: "POST",
|
||||
headers: {
|
||||
"content-type": "application/json"
|
||||
}
|
||||
}).then(async res => setSponsors(await res.json()))
|
||||
}
|
||||
asyncFunction()
|
||||
}, [])
|
||||
return sponsors.data ? (
|
||||
<div className={styles.sponsorLayout}>
|
||||
{sponsors.data?.account?.contributors?.nodes.filter(sp => sp.totalAmountDonated > 0).map((sponsor, index) => (
|
||||
<div key={index} className={styles.sponsorCard}>
|
||||
<a href={`https://opencollective.com/${sponsor.collectiveSlug}`}>
|
||||
<img src={sponsor.image} alt={sponsor.name}/>
|
||||
<h3>{sponsor.name}{sponsor.isAdmin && ' (admin)'}</h3>
|
||||
</a>
|
||||
<p>{sponsor.publicMessage}</p>
|
||||
<p className={styles.sponsorMoney}>${sponsor.totalAmountDonated / 100}</p>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
) : <LoadingIcon size={100}/>
|
||||
}
|
||||
|
||||
function LoadingIcon({ size }) {
|
||||
return (
|
||||
<svg xmlns="http://www.w3.org/2000/svg" className="icon icon-tabler icon-tabler-loader-2" width="44" height="44"
|
||||
viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round"
|
||||
stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M12 3a9 9 0 1 0 9 9">
|
||||
<animateTransform attributeName="transform" type="rotate" from="0 12 12" to="360 12 12"
|
||||
dur="0.5s" repeatCount="indefinite"/>
|
||||
</path>
|
||||
</svg>
|
||||
)
|
||||
}
|
||||
|
||||
/*
|
||||
type Response = {
|
||||
data: {
|
||||
account: Account;
|
||||
};
|
||||
};
|
||||
|
||||
type Account = {
|
||||
id: string;
|
||||
currency: string;
|
||||
slug: string;
|
||||
contributors: Contributors;
|
||||
__typename: string;
|
||||
};
|
||||
|
||||
type Contributors = {
|
||||
totalCount: number;
|
||||
nodes: Contributor[];
|
||||
__typename: string;
|
||||
};
|
||||
|
||||
type Contributor = {
|
||||
id: string;
|
||||
name: string;
|
||||
roles: string[];
|
||||
isAdmin: boolean;
|
||||
isCore: boolean;
|
||||
isBacker: boolean;
|
||||
since: string;
|
||||
image: string;
|
||||
description: string | null;
|
||||
collectiveSlug: string;
|
||||
totalAmountDonated: number;
|
||||
type: string;
|
||||
publicMessage: string | null;
|
||||
isIncognito: boolean;
|
||||
__typename: string;
|
||||
};
|
||||
*/
|
||||
@@ -1,42 +0,0 @@
|
||||
.sponsorLayout {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
margin: 0 auto;
|
||||
max-width: 1500px;
|
||||
}
|
||||
.sponsorCard {
|
||||
margin: 1rem;
|
||||
text-align: center;
|
||||
background: #deddda;
|
||||
border-radius: 15px;
|
||||
padding: 1rem;
|
||||
transition: transform 0.3s;
|
||||
width: 200px;
|
||||
white-space: break-spaces;
|
||||
overflow: hidden !important;
|
||||
text-overflow: ellipsis;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: flex-start;
|
||||
align-items: center;
|
||||
height: 350px;
|
||||
}
|
||||
.sponsorMoney {
|
||||
font-size: 1.5rem;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
margin-top: auto;
|
||||
}
|
||||
.sponsorCard img {
|
||||
width: 92px;
|
||||
height: 92px;
|
||||
aspect-ratio: 1/1;
|
||||
border-radius: 50%;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .sponsorCard {
|
||||
background: #282828;
|
||||
color: white;
|
||||
}
|
||||
@@ -38,27 +38,7 @@
|
||||
--ifm-color-primary-light: #ffffff;
|
||||
--ifm-color-primary-lighter: #ffffff;
|
||||
--ifm-color-primary-lightest: #ffffff;
|
||||
--ifm-background-color: #242526;
|
||||
--docusaurus-highlighted-code-line-bg: rgba(82, 78, 183, 0.3);
|
||||
--ifm-font-family-monospace: 'JetBrains Mono', 'Fira Code', 'Meslo NGF', 'Menlo', SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', monospace;
|
||||
--ifm-navbar-background-color :#66002a
|
||||
}
|
||||
|
||||
button {
|
||||
background-color: var(--ifm-color-primary);
|
||||
transition: background-color 0.3s;
|
||||
color: var(--ifm-background-color);
|
||||
border: none;
|
||||
padding: 0.5rem 1rem;
|
||||
border-radius: 0.5rem;
|
||||
cursor: pointer;
|
||||
}
|
||||
button:hover {
|
||||
/* change the color of the button when hovered, with a bit of a transition */
|
||||
background-color: var(--ifm-color-primary-dark);
|
||||
transition: background-color 0.3s;
|
||||
}
|
||||
/* replicate the button parallax that for example material design has */
|
||||
button:active {
|
||||
transform: translateY(0.09rem);
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
import { useEffect, useState } from "react";
|
||||
|
||||
export default function useTheme() {
|
||||
const [theme, setTheme] = useState(window.localStorage.getItem('theme'));
|
||||
|
||||
useEffect(() => {
|
||||
window.addEventListener('storage', (e) => {
|
||||
e.key === 'theme' && setTheme(e.newValue);
|
||||
})
|
||||
}, []);
|
||||
|
||||
return [theme, setTheme];
|
||||
}
|
||||
@@ -48,10 +48,13 @@ export default function Home() {
|
||||
return (
|
||||
<Layout
|
||||
title="sern - Handlers. Redefined."
|
||||
description="Description will go into a meta tag in">
|
||||
description="Description will go into a meta tag in"
|
||||
>
|
||||
<HomepageHeader/>
|
||||
<main className='user-select-none'>
|
||||
<div>
|
||||
<HomepageFeatures/>
|
||||
</div>
|
||||
</main>
|
||||
</Layout>
|
||||
);
|
||||
|
||||
@@ -4,15 +4,12 @@
|
||||
*/
|
||||
|
||||
.heroBanner {
|
||||
padding: 64px;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 1rem;
|
||||
}
|
||||
|
||||
.buttons {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -25,11 +22,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
.cntnr {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
max-width: 1500px;
|
||||
gap: 1rem;
|
||||
margin: 2rem auto;
|
||||
herotitle_font {
|
||||
font-size: auto
|
||||
}
|
||||
@@ -2,32 +2,17 @@ import React from 'react';
|
||||
import Layout from '@theme/Layout';
|
||||
import clsx from "clsx";
|
||||
import styles from "./index.module.css";
|
||||
import PluginCard from "../components/PluginCard";
|
||||
|
||||
export default function Plugins() {
|
||||
const [pluginList, setPluginList] = React.useState([])
|
||||
React.useEffect(() => {
|
||||
const asyncFetch = async () => {
|
||||
const response = await fetch('https://raw.githubusercontent.com/sern-handler/awesome-plugins/main/pluginlist.json')
|
||||
const data = await response.json()
|
||||
data.forEach(pl => {
|
||||
pl.trimmedDescription = pl.description.length > 100 ? pl.description.slice(0, 100) + "..." : pl.description
|
||||
})
|
||||
setPluginList(data)
|
||||
}
|
||||
asyncFetch()
|
||||
}, [])
|
||||
|
||||
return (
|
||||
<Layout>
|
||||
<h1 className={styles.header}>
|
||||
Plugins
|
||||
</h1>
|
||||
<div className={styles.cntnr}>
|
||||
{pluginList.map(p => (
|
||||
<PluginCard plugin={p} key={p.hash} />
|
||||
))}
|
||||
</div>
|
||||
<header className={clsx('hero hero--primary-darker', styles.heroBanner)}>
|
||||
<h1 className={"hero__title"}>
|
||||
Coming soon
|
||||
</h1>
|
||||
</header>
|
||||
|
||||
</Layout>
|
||||
)
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
.container {
|
||||
max-width: fit-content;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 1rem;
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
import './sponsors.css';
|
||||
import Layout from '@theme/Layout';
|
||||
import Sponsors from "../components/Sponsors";
|
||||
export default function ( ) {
|
||||
return (
|
||||
<Layout>
|
||||
<header className='header'>
|
||||
<h1 className={"hero__title"}>
|
||||
Sponsors
|
||||
</h1>
|
||||
<p className={"hero__subtitle"}>
|
||||
These amazing people help us keep the project alive. A big thanks from the team!
|
||||
</p>
|
||||
</header>
|
||||
<Sponsors />
|
||||
</Layout>
|
||||
)
|
||||
}
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 39 KiB |
Reference in New Issue
Block a user