Hacker News new | ask | show | jobs
by spankalee 1600 days ago
I think you're misunderstanding web components: Web components aren't an internal implementation - they can have any internal implementation the author wants to use - they're an external interface.

You can build web components with React, Svelte, Lit, Stencil, or just vanilla JS. Given that blocks need an interface, it'd be nice to extend a standard with whatever else you need rather than go completely parallel to the standard.

1 comments

I appreciate that you can use whatever JS you want when constructing custom elements.

To date we've been looking at how apps can deal with different ways in which blocks can be exposed to the app, but haven't ruled out specifying that they must be exposed in a fixed way - this would make it more consistent, at the cost (which may well be small and largely automatable) of requiring authors to wrap their block, e.g. with a custom element definition.

I'd be interested to talk in more detail about how that might work with relation to the current web component spec and future plans / other work in train: c@hash.ai if you're up for it