Skip to content

linter: rulegen tool is broken #18322

@connorshea

Description

@connorshea

just new-react-rule no-multi-comp now results in:

failed to add no-multi-comp to rules file: failed to find 'declare_all_lint_rules!' in crates/oxc_linter/src/rules.rs

And the rule doesn't get added properly to the linter after the rule file is generated. This is because of the changes in #18076 not updating the rulegen logic, I assume?

This method needs to be updated to define the rule however we want to do that now:

fn add_rules_entry(ctx: &Context, rule_kind: RuleKind) -> Result<(), Box<dyn std::error::Error>> {

(or that method should be removed, I guess)

Metadata

Metadata

Assignees

Labels

Type

Priority

None yet

Effort

None yet

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions