How I Write Custom Elements with lit-html
You can use a smaller part of Lit to build web web components that still take advantage of some of it’s best features, particularly if you’re cool with Light DOM.
You can use a smaller part of Lit to build web web components that still take advantage of some of it’s best features, particularly if you’re cool with Light DOM.
Exploring a Card component made hyper flexible though use of easily changeable custom properties, props, and slots.
One of the nice things about Markdown is that you can just… put HTML in there too. There is no Markdown shortcut for a <div>, but you can just use a <div>. That means you can use use <my-custom-element> as well, bringing the world of Web Components into your writing and creating of content. Deane […]
For who-knows-what reason color inputs only show a color swatch, not a string representation of the color. Let’s see if we can fix that.
Bluesky is enjoying a boon in popularity. The API access right now is nicely open, allowing people to create some interesting stuff around it. I like this idea from Matt Kane: a Web Component (<bluesky-comments>) that loads up all the replies to any particular post like a comment thread. Imagine there is a post for […]
“… props that match a property on the Custom Element instance will be assigned as properties, otherwise they will be assigned as attributes.”
These custom video (and audio) players are very nice. I like how the accommodate narrow/vertical video players and work with any video provider (even YouTube).
The other day I needed to quickly see pixel dimensions that were exactly in a 9 / 16 aspect ratio. Like: 180 / 320. That’s perfectly in that ratio. You might be able to think of that one in your head, but how about 351 / 624? That’s harder to think of. And I wanted […]
I thought the Bytes newsletter #326 did a good job of showing the different between a “normal” web component and a “declarative shadow DOM” web component. (Quick ports of the former and latter). Declarative shadow DOM is the web components story for “server-side rendering” (SSR). All the visual stuff needed to render the component is […]
There is a meta conversation of “Web Components are very definitely going to be around 10 years from now while any JavaScript framework today will not” is worth considering, but pits the two directly against each other when we really don’t need to.
Frontend Masters donates to open source projects through thanks.dev and Open Collective, as well as donates to non-profits like The Last Mile, Annie Canons, and Vets Who Code.