From b3dfb0ab519b9148e69fad81881ff7fb9f0d3138 Mon Sep 17 00:00:00 2001 From: Shannon Rothe Date: Tue, 7 Mar 2023 09:25:14 +1100 Subject: [PATCH] chore(linter): remove extra spacing (#141) --- crates/oxc_linter/src/rules/deepscan/uninvoked_array_callback.rs | 1 - crates/oxc_linter/src/rules/for_direction.rs | 1 - crates/oxc_linter/src/rules/no_array_constructor.rs | 1 - crates/oxc_linter/src/rules/no_debugger.rs | 1 - crates/oxc_linter/src/rules/no_empty.rs | 1 - 5 files changed, 5 deletions(-) diff --git a/crates/oxc_linter/src/rules/deepscan/uninvoked_array_callback.rs b/crates/oxc_linter/src/rules/deepscan/uninvoked_array_callback.rs index 733afaf7f..a1a5ae91e 100644 --- a/crates/oxc_linter/src/rules/deepscan/uninvoked_array_callback.rs +++ b/crates/oxc_linter/src/rules/deepscan/uninvoked_array_callback.rs @@ -33,7 +33,6 @@ declare_oxc_lint!( /// When the Array constructor is called with a single number argument, an array with the specified number of empty slots (not actual undefined values) is constructed. /// If a callback function is passed to the function of this array, the callback function is never invoked because the array has no actual elements. /// - /// /// ### Example /// ```javascript /// const list = new Array(5).map(_ => createElement()); diff --git a/crates/oxc_linter/src/rules/for_direction.rs b/crates/oxc_linter/src/rules/for_direction.rs index 260dd115e..3f94ebf31 100644 --- a/crates/oxc_linter/src/rules/for_direction.rs +++ b/crates/oxc_linter/src/rules/for_direction.rs @@ -33,7 +33,6 @@ declare_oxc_lint!( /// ### Why is this bad? /// A for loop that is known to run infinitely or never run is considered a bug. /// - /// /// ### Example /// ```javascript /// for (var i = 0; i < 10; i--) {} diff --git a/crates/oxc_linter/src/rules/no_array_constructor.rs b/crates/oxc_linter/src/rules/no_array_constructor.rs index 17c8d5d10..99c7b1e91 100644 --- a/crates/oxc_linter/src/rules/no_array_constructor.rs +++ b/crates/oxc_linter/src/rules/no_array_constructor.rs @@ -23,7 +23,6 @@ declare_oxc_lint!( /// Use of the Array constructor to construct a new array is generally discouraged in favor of array literal notation because of the single-argument pitfall and because the Array global may be redefined. /// The exception is when the Array constructor is used to intentionally create sparse arrays of a specified size by giving the constructor a single numeric argument. /// - /// /// ### Example /// ```javascript /// let arr = new Array(); diff --git a/crates/oxc_linter/src/rules/no_debugger.rs b/crates/oxc_linter/src/rules/no_debugger.rs index c97a37319..1b2021688 100644 --- a/crates/oxc_linter/src/rules/no_debugger.rs +++ b/crates/oxc_linter/src/rules/no_debugger.rs @@ -23,7 +23,6 @@ declare_oxc_lint!( /// `debugger` statements do not affect functionality when a debugger isn't attached. /// They're most commonly an accidental debugging leftover. /// - /// /// ### Example /// ```javascript /// const data = await getData(); diff --git a/crates/oxc_linter/src/rules/no_empty.rs b/crates/oxc_linter/src/rules/no_empty.rs index c64456033..a6fc6b164 100644 --- a/crates/oxc_linter/src/rules/no_empty.rs +++ b/crates/oxc_linter/src/rules/no_empty.rs @@ -25,7 +25,6 @@ declare_oxc_lint!( /// Empty block statements, while not technically errors, usually occur due to refactoring that wasn’t completed. /// They can cause confusion when reading code. /// - /// /// ### Example /// ```javascript /// if (condition) {