Skip to content

Commit

Permalink
chore: rename the rule from noArrayConstructor to useArrayLiterals
Browse files Browse the repository at this point in the history
ref: #2532
  • Loading branch information
Kazuhiro-Mimaki committed Apr 23, 2024
1 parent 2b3b810 commit c991d50
Show file tree
Hide file tree
Showing 12 changed files with 72 additions and 72 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

90 changes: 45 additions & 45 deletions crates/biome_configuration/src/linter/rules.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion crates/biome_diagnostics_categories/src/categories.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ define_categories! {
"lint/correctness/useValidForDirection": "https://biomejs.dev/linter/rules/use-valid-for-direction",
"lint/correctness/useYield": "https://biomejs.dev/linter/rules/use-yield",
"lint/nursery/colorNoInvalidHex": "https://biomejs.dev/linter/rules/color-no-invalid-hex",
"lint/nursery/noArrayConstructor": "https://biomejs.dev/linter/rules/no-array-constructor",
"lint/nursery/useArrayLiterals": "https://biomejs.dev/linter/rules/no-array-constructor",
"lint/nursery/noColorInvalidHex": "https://biomejs.dev/linter/rules/no-color-invalid-hex",
"lint/nursery/noConsole": "https://biomejs.dev/linter/rules/no-console",
"lint/nursery/noConstantMathMinMaxClamp": "https://biomejs.dev/linter/rules/no-constant-math-min-max-clamp",
Expand Down
4 changes: 2 additions & 2 deletions crates/biome_js_analyze/src/lint/nursery.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -41,16 +41,16 @@ declare_rule! {
/// [0, 1, 2];
/// ```
///
pub NoArrayConstructor {
pub UseArrayLiterals {
version: "next",
name: "noArrayConstructor",
name: "useArrayLiterals",
sources: &[RuleSource::Eslint("no-array-constructor")],
recommended: false,
fix_kind: FixKind::Unsafe,
}
}

impl Rule for NoArrayConstructor {
impl Rule for UseArrayLiterals {
type Query = Ast<JsExpressionStatement>;
type State = ();
type Signals = Option<Self::State>;
Expand Down
4 changes: 2 additions & 2 deletions crates/biome_js_analyze/src/options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ pub type NoApproximativeNumericConstant = < lint :: suspicious :: no_approximati
pub type NoArguments = <lint::style::no_arguments::NoArguments as biome_analyze::Rule>::Options;
pub type NoAriaHiddenOnFocusable = < lint :: a11y :: no_aria_hidden_on_focusable :: NoAriaHiddenOnFocusable as biome_analyze :: Rule > :: Options ;
pub type NoAriaUnsupportedElements = < lint :: a11y :: no_aria_unsupported_elements :: NoAriaUnsupportedElements as biome_analyze :: Rule > :: Options ;
pub type NoArrayConstructor =
<lint::nursery::no_array_constructor::NoArrayConstructor as biome_analyze::Rule>::Options;
pub type NoArrayIndexKey =
<lint::suspicious::no_array_index_key::NoArrayIndexKey as biome_analyze::Rule>::Options;
pub type NoAssignInExpressions = < lint :: suspicious :: no_assign_in_expressions :: NoAssignInExpressions as biome_analyze :: Rule > :: Options ;
Expand Down Expand Up @@ -247,6 +245,8 @@ pub type UseAnchorContent =
pub type UseAriaActivedescendantWithTabindex = < lint :: a11y :: use_aria_activedescendant_with_tabindex :: UseAriaActivedescendantWithTabindex as biome_analyze :: Rule > :: Options ;
pub type UseAriaPropsForRole =
<lint::a11y::use_aria_props_for_role::UseAriaPropsForRole as biome_analyze::Rule>::Options;
pub type UseArrayLiterals =
<lint::nursery::use_array_literals::UseArrayLiterals as biome_analyze::Rule>::Options;
pub type UseArrowFunction =
<lint::complexity::use_arrow_function::UseArrowFunction as biome_analyze::Rule>::Options;
pub type UseAsConstAssertion =
Expand Down
Loading

0 comments on commit c991d50

Please sign in to comment.