From becc8f4b2580cb30acd24471e536249b54f298d7 Mon Sep 17 00:00:00 2001 From: Ilya Azin Date: Tue, 17 Nov 2020 13:46:48 +0300 Subject: [PATCH] refactor(max-tags-file): modify meta, specify types #9 --- lib/rules/max-tags-file.js | 29 ++++++++++++++--------------- 1 file changed, 14 insertions(+), 15 deletions(-) diff --git a/lib/rules/max-tags-file.js b/lib/rules/max-tags-file.js index a45f94c..e1e2a6a 100644 --- a/lib/rules/max-tags-file.js +++ b/lib/rules/max-tags-file.js @@ -18,8 +18,8 @@ const DEFAULT_MAX_TAGS = 4; let maxTags = DEFAULT_MAX_TAGS; /** - * * @param {import("eslint").Rule.RuleContext} context + * @return {import("eslint").Rule.RuleListener} */ function create(context) { const code = context.getSourceCode(); @@ -59,23 +59,22 @@ function create(context) { //---------------------------------------------------------------------- return { - message: `Occured` // give me methods - }; } -module.exports = { - create, - meta: { - docs: { - description: "Limit TODO/FIXME tags amount in file", - category: "Fill me in", - recommended: false - }, - fixable: null, // or "code" or "whitespace" - schema: [ - // fill in your schema - ] +/** + * @type {import("eslint").Rule.RuleMetaData} + */ +const meta = { + docs: { + description: "Limit TODO/FIXME tags amount in file", + recommended: true, }, + fixable: null, // or "code" or "whitespace" + schema: [ + // fill in your schema + ] }; + +module.exports = { create, meta };