DEV Community


Discussion on: Web Components in Style

deadwisdom profile image
Brantley Harris Author

I think Svelte is really interesting because it has a compilation step. That is a double-edged sword because it means you are abstracted from the final component. The LitElement I make is directly inherited from an HTMLElement, so I have a much stronger feeling of being close to the metal, so to speak. BUT the compilation step means no dependencies, or at least very few. So your end product is maybe the lightest-weight component possible. Also, compilation lets Svelte do cool things that something like LitElement readily couldn't. Trade-offs.

Overall I think just use what appeals to you. Highly recommend trying a few different ones so you don't get yourself stuck in a mindset.