3 ms·
Very good! I can already see Lit-Element[0], one of the beneficiaries, leveraging this! When I first started writing/exploring Shadow DOM API I felt so weird w
by rickstanley 4y ago
Very good! I can already see Lit-Element[0], one of the beneficiaries, leveraging this!
When I first started writing/exploring Shadow DOM API I felt so weird writing inline `class`, but then again, it's just a syntactic sugar for prototype functions.
- [0]: https://lit.dev/docs/ssr/overview/ https://lit.dev/docs/ssr/overview/
- azangru 4y ago> I felt so weird writing inline `class`, but then again, it's just a syntactic sugar for prototype functions You felt weird using standard ES6 syntax? Did you prefer writing Thing.prototype.method = function(){}... ? Or Derived.prototype = Object.create(Base.prototype)?
- rezonant 4y agoI think they mean class expression (ie const c = class {}) versus class declaration (class c {}). Both are indeed ES standard though.