solidjs-community / eslint-plugin-solid

Solid-specific linting rules for ESLint.
MIT License
216 stars 26 forks source link

prefer-classlist rule should be removed from recommended configs #34

Closed joshwilsonvu closed 1 year ago

joshwilsonvu commented 1 year ago

Though the classList prop on native elements has been presented in the docs as an alternative to using a classnames helper like clsx, it is now considered regrettable—see the conversation around this Discord message. Essentially, it places more burden on TS typing and library maintenance, without much upside.

The solid/prefer-classlist rule has been autofixing helpers to classList, pushing people in the wrong direction. I wouldn't go so far as to start autofixing the other way, as users may not have classnames helpers available, but we should at least remove the rule from recommended configs and possibly deprecate it.