mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-18 04:23:31 +01:00
docs: guide setup (#10862)
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
{
|
||||
"files": ["src/**/*.js", "test/**/*.js"],
|
||||
"extends": ["eslint:recommended"],
|
||||
"plugins": ["import"],
|
||||
"plugins": ["import", "jsdoc"],
|
||||
"parserOptions": {
|
||||
"ecmaVersion": 2022
|
||||
},
|
||||
@@ -13,6 +13,29 @@
|
||||
"es2022": true,
|
||||
"node": true
|
||||
},
|
||||
"settings": {
|
||||
"jsdoc": {
|
||||
"tagNamePreference": {
|
||||
"augments": "extends",
|
||||
"return": "returns",
|
||||
"arg": "param",
|
||||
"fires": "emits",
|
||||
"function": "method"
|
||||
},
|
||||
"preferredTypes": {
|
||||
"String": "string",
|
||||
"Number": "number",
|
||||
"Boolean": "boolean",
|
||||
"Symbol": "symbol",
|
||||
"object": "Object",
|
||||
"function": "Function",
|
||||
"array": "Array",
|
||||
"date": "Date",
|
||||
"error": "Error",
|
||||
"null": "void"
|
||||
}
|
||||
}
|
||||
},
|
||||
"rules": {
|
||||
"import/order": [
|
||||
"error",
|
||||
@@ -29,29 +52,10 @@
|
||||
"no-compare-neg-zero": "error",
|
||||
"no-template-curly-in-string": "error",
|
||||
"no-unsafe-negation": "error",
|
||||
"valid-jsdoc": [
|
||||
"error",
|
||||
{
|
||||
"requireReturn": false,
|
||||
"requireReturnDescription": false,
|
||||
"prefer": {
|
||||
"return": "returns",
|
||||
"arg": "param"
|
||||
},
|
||||
"preferType": {
|
||||
"String": "string",
|
||||
"Number": "number",
|
||||
"Boolean": "boolean",
|
||||
"Symbol": "symbol",
|
||||
"object": "Object",
|
||||
"function": "Function",
|
||||
"array": "Array",
|
||||
"date": "Date",
|
||||
"error": "Error",
|
||||
"null": "void"
|
||||
}
|
||||
}
|
||||
],
|
||||
"jsdoc/require-returns": "off",
|
||||
"jsdoc/require-returns-description": "off",
|
||||
"jsdoc/check-tag-names": "error",
|
||||
"jsdoc/check-types": "error",
|
||||
|
||||
"accessor-pairs": "warn",
|
||||
"array-callback-return": "error",
|
||||
|
||||
@@ -85,20 +85,21 @@
|
||||
"@discordjs/docgen": "workspace:^",
|
||||
"@discordjs/scripts": "workspace:^",
|
||||
"@favware/cliff-jumper": "^4.1.0",
|
||||
"@types/node": "^22.14.0",
|
||||
"@typescript-eslint/eslint-plugin": "^8.29.0",
|
||||
"@types/node": "^22.15.2",
|
||||
"@typescript-eslint/eslint-plugin": "^8.31.0",
|
||||
"@typescript-eslint/parser": "^8.29.0",
|
||||
"cross-env": "^7.0.3",
|
||||
"dtslint": "4.2.1",
|
||||
"eslint": "^8.57.1",
|
||||
"eslint": "^9.25.1",
|
||||
"eslint-formatter-compact": "^8.40.0",
|
||||
"eslint-formatter-pretty": "^5.0.0",
|
||||
"eslint-plugin-import": "^2.31.0",
|
||||
"eslint-plugin-jsdoc": "^50.6.11",
|
||||
"jest": "29.7.0",
|
||||
"prettier": "^3.5.3",
|
||||
"tsd": "^0.31.2",
|
||||
"tslint": "6.1.3",
|
||||
"turbo": "^2.5.0",
|
||||
"turbo": "^2.5.2",
|
||||
"typescript": "~5.8.3"
|
||||
},
|
||||
"engines": {
|
||||
|
||||
@@ -65,7 +65,7 @@ class WebhookClient extends BaseClient {
|
||||
*/
|
||||
|
||||
// These are here only for documentation purposes - they are implemented by Webhook
|
||||
/* eslint-disable no-empty-function, valid-jsdoc */
|
||||
/* eslint-disable no-empty-function */
|
||||
/**
|
||||
* Sends a message with this webhook.
|
||||
* @param {string|MessagePayload|WebhookMessageCreateOptions} options The content for the reply
|
||||
|
||||
@@ -23,7 +23,7 @@ const { ComponentType } = require('discord-api-types/v10');
|
||||
*/
|
||||
|
||||
/**
|
||||
* @typedef {object} SelectMenuComponentOptionData
|
||||
* @typedef {Object} SelectMenuComponentOptionData
|
||||
* @property {string} label The label of the option
|
||||
* @property {string} value The value of the option
|
||||
* @property {?string} description The description of the option
|
||||
|
||||
Reference in New Issue
Block a user