Netflix / x-element

A dead simple starting point for custom elements.
Apache License 2.0
28 stars 12 forks source link

Discussion: Should we get rid of the computed DSL? #36

Closed theengineear closed 3 years ago

theengineear commented 5 years ago

The DSL was a convenience ported over from Polymer. However, this forces us to do some additional parsing work. From the perspective of staying lean, this could just be considered bloat.

Here's a potentially better, more declarative way forward:

computed: ['computeC', 'a', 'b']

That doesn't feel terribly hard to write out to me and then there's basically no guesswork as to what could be happening here.

klebba commented 5 years ago

I'm not sure this is less confusing; the syntax is definitely difficult to scan. It also seems like you could add function or variable array members here, but this would be bad