runem / lit-analyzer

Monorepository for tools that analyze lit-html templates
MIT License
314 stars 35 forks source link

Does this plugin work? #358

Open helgardferreira opened 1 month ago

helgardferreira commented 1 month ago

I'm getting false flags when I'm using converters on @property for both no-incompatible-property-type and no-incompatible-type-binding. I can remove the no-incompatible-property-type error by not using ComplexAttributeConverter but no matter what I do no-incompatible-type-binding is a PITA.

I've seen multiple issues of this on the repo and at this stage I'm wondering why no-incompatible-type-binding even exists? no-incompatible-property-type makes some sense to prevent developers from using @property for complex types without an accompanying converter but no-incompatible-type-binding makes essentially zero sense since attributes from the DOM perspective are always string??

Either the type system for no-incompatible-type-binding needs to be improved or just flat-out remove the rule. At this point it seems I either have to litter my codebase with @ts-ignore, @ts-expect-error, or just fork this project and remove the superfluous rule.