From b95b6e95d022c289d2640802e6f621f68f91759f Mon Sep 17 00:00:00 2001 From: ChihebSMIDA Date: Thu, 30 May 2024 09:57:51 +0200 Subject: [PATCH] [ec36-avoid-autoplay] fix : eslint --- eslint-plugin/lib/rules/avoid-autoplay.js | 103 +++++++++--------- .../tests/lib/rules/avoid-autoplay.js | 72 ++++++------ 2 files changed, 88 insertions(+), 87 deletions(-) diff --git a/eslint-plugin/lib/rules/avoid-autoplay.js b/eslint-plugin/lib/rules/avoid-autoplay.js index 6f95c3f..e8bec83 100644 --- a/eslint-plugin/lib/rules/avoid-autoplay.js +++ b/eslint-plugin/lib/rules/avoid-autoplay.js @@ -18,56 +18,61 @@ "use strict"; -/** @type {import('eslint').Rule.RuleModule} */ +/** @type {import("eslint").Rule.RuleModule} */ module.exports = { - meta: { - type: "suggestion", - docs: { - description: "Disallow autoplay and enforce preload='none' for video and audio elements", - category: "eco-design", - recommended: "warn", - }, - messages: { - NoAutoplay: "Avoid using autoplay attribute for