runem / lit-analyzer

Monorepository for tools that analyze lit-html templates
MIT License
318 stars 36 forks source link

changedProperties check if name is actually a @property or @state #166

Open Christian24 opened 3 years ago

Christian24 commented 3 years ago

Hello,

In Lit a lot of lifecycle callbacks use a Map called changedProperties which holds all properties that changed during the update. For example changedProperties.has('foo') says if property foo changed. If you rename the property foo now, you also need to rename it where ever you use it in changedProperties. This is error prone and a rule that would detect property names that are not actual properties would help ease the pain a little bit.