get-alex / alex

Catch insensitive, inconsiderate writing
https://alexjs.com
MIT License
4.81k stars 207 forks source link

Expose rule groups like `gender`, `sexuality`, `race`, `religion`... #335

Open etrobert opened 1 year ago

etrobert commented 1 year ago

Subject of the feature

Expose rule groups like gender, sexuality, race, religion...

Problem

For gradual adoption in our codebase, we would like to enable certain groups of rules by topic.

Expected behaviour

Allow to select rule groups in allow and deny, for example with deny: ['group:gender']

Alternatives

Ideally, this categorisation would be done by retext.

Alternatively, we are doing this same categorization in our local codebase.

wooorm commented 1 year ago

Hmm. Interesting idea, to help folks adopt this gradually. All messages have a ruleId. So they can definitely be filtered. They don’t have a category through. That would be the thing to work on first. I’m not really sure that these categories that are in retext-equality are great or precide though. They’re more... loose categorizations so we don’t have one giant file.

Maybe the diff functionality is a better way to start gradually? https://github.com/get-alex/alex#workflow. Or, start with a smaller list of files and add more later?