Mickaël Oth

@mickaeloth.dev

🌐 Web & mobile dev ✨ DX / UX / UI 🪄 JavaScript / TypeScript 💚 Vue.js

How to determine if it's a nav with tabbable links or ARIA tabs: Design comes first. Then, semantic HTML. If needed, ARIA follows. Designers should first consider how users will engage with a widget and the rest of the page, always striving for the best user experience.

Four links visually presented as a horizontal tab list

JavaScript tip: You can name your capture groups in regular expressions for better readability. Syntax: (?<name>x)

const text = "First: Diego, Last: Haz";
const regex = /First: (?<first>\w+), Last: (?<last>\w+)/;
const match = text.match(regex);

match.groups.first; // Diego
match.groups.last; // Haz

We are really considering dropping Vue 2 and going Vue 3 only, as the misalignments between them became harder to smooth out. Any objections or ideas?

🎉 After six incredible years at Framer, it’s time for my next step. Today, we’re spinning Framer Motion out as its own independent open-source project, to better serve the whole community. Introducing Motion. For React, and now, for everyone.

JavaScript tip: Use Unicode regular expressions to match letters in any language. \p{L} - Letter in any language \p{Z} - Whitespace or invisible separator \p{S} - Symbol \p{N} - Number in any script \p{P} - Punctuation You can also match characters NOT belonging to the group by uppercasing \P

A screenshot showing a list of regular expressions attempting to match words from various languages.

Full code:

/^[a-z]+$/i.test("car"); // ✅ true
/^[a-z]+$/i.test("pão"); // ❌ false
/^[a-z]+$/i.test("知道"); // ❌ false
/^[a-z]+$/i.test("يعرف"); // ❌ false

/^\p{L}+$/u.test("car"); // ✅ true
/^\p{L}+$/u.test("pão"); // ✅ true
/^\p{L}+$/u.test("知道"); // ✅ true
/^\p{L}+$/u.test("يعرف"); // ✅ true

😮 Bluesky pro-tip: in the accessibility settings, you can enforce that the images you post must have alt text. This is important for folks who use screen readers. Instead of seeing the image, the supplied text will be read to them instead.

Screenshot of the Bluesky settings page, under "Accessibility Settings". There is a toggle labeled "Require alt text before posting".