googlearchive / polylint

Lint polymer!
BSD 3-Clause "New" or "Revised" License
116 stars 19 forks source link

add a linter for camel case attributes on custom elements #126

Closed 43081j closed 7 years ago

43081j commented 8 years ago

Fixes #58.

Simply takes any camel cased properties from the element definition and checks if a lowercased version exists on the instance of it (the tag).

This works because parse5 normalises attributes, such that fooBar becomes foobar. So if we have a property named fooBar and our parse5 node has foobar, we know it was originally written as <our-el fooBar>.

43081j commented 7 years ago

polymer-linter can achieve this now.