A blog about web development, HTML, CSS, JavaScript, and web accessibility.

Parents counting children in CSS

The other day I was driving home when suddenly it hit me: We can use :has() to determine how many children a parent element has.

outline is your friend

If you open a plain HTML document with no CSS and you focus an interactive element like a button, link, or textarea, you’ll see that by default browsers use the outline property to highlight these elements.

Analyzing pages in a particular state with Lighthouse

Historically, Lighthouse has analyzed the cold pageload of a page only. Clicking the “Generate report” button reloads the page before Lighthouse runs its tests. This can be problematic when you want to run tests on parts of the UI that are only visible when the user interacts with it. For example, a fly-out navigation, a modal window, or the content in a disclosure widget.

Divs are bad!

Yes, clickbait, I’m so sorry! Of course, divs are not bad. For example, they can be really useful,…

  • …when you need additional elements for styling.
  • …for structuring content, when there’s no other suitable element.
  • …when you need custom landmarks.

Even though there’s nothing wrong with the div per se, some people, including me, still like to complain when they’re not used consciously.

Please, stop disabling zoom

I know that you’re not supposed to tell people what to do, but in this particular case I’m really tempted because recently I’ve noticed that a lot of websites are preventing users on mobile to zoom.

Bonn Meetup 7: Introduction to web accessibility and deceitful Lighthouse scores

This week I’ll be speaking at the Bonn Code Meetup about accessibility testing. I’m joining Konstantin Tieber who’ll talk about the What, Why, Who and How of building accessible web applications. I’ll show you how I built “The Most Inaccessible Site Possible With A Perfect Lighthouse Score”.

Web Security Basics: XSS

I decided to learn more about areas of web development I don’t know a lot about. You know,…stuff like SEO and web security. I’ll share my findings here on my blog and I’ll try to do as much research as possible, but please keep in mind that I’m a noob concerning these topics.

Cascade Layers: First Contact

Earlier this week I learned about CSS Cascade Layers and now I’m all hyped up because I really like the concept. I’m eager to find out how we can use them to improve and rethink the architecture of our styles.

CSS Specificity Demo

I built an interactive demo to illustrate how specificity in CSS works.

Here’s what I didn’t know about :where()

This is part 4 of my series Here’s what I didn’t know about… in which I try to learn new things about CSS. This time I'm trying to find out what I didn’t know about the :where() pseudo-class.