Firefox for Web Developers's Avatar

Firefox for Web Developers

@webdevs.firefox.com

Official Firefox account for people who build on the web. Learn about the things we're working on to grow and improve the web platform.

1,987
Followers
6
Following
219
Posts
22.11.2024
Joined
Posts Following

Latest posts by Firefox for Web Developers @webdevs.firefox.com

Preview
Iterator.zip() - JavaScript | MDN The Iterator.zip() static method creates a new Iterator object that aggregates elements from multiple iterable objects by yielding arrays containing elements at the same position. It essentially…

For more demos and links to polyfills, head over to MDN developer.mozilla.org/en-US/docs/W...

05.03.2026 14:16 πŸ‘ 4 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Video thumbnail

JavaScript Iteratorβ€€zip landed in Firefox 148, making it simple to loop over multiple things at the same time. Here's how it works:

05.03.2026 14:16 πŸ‘ 95 πŸ” 18 πŸ’¬ 8 πŸ“Œ 1
Heart CSS shape

It is! Here's the demo random-stuff.jakearchibald.com/heart-css-sh...

It uses linear() - one of the standards I worked on.

I also built a little tool to help generate spring easings linear-easing-generator.netlify.app

03.03.2026 15:33 πŸ‘ 2 πŸ” 1 πŸ’¬ 1 πŸ“Œ 0
The UI as before, but with no button to suggest other tabs. The entry point has been removed.

The UI as before, but with no button to suggest other tabs. The entry point has been removed.

If you have blocked AI enhancements, this is the same UI - the entry point to the feature isn't there.

And of course, any already-downloaded models are deleted.

03.03.2026 14:36 πŸ‘ 3 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0
"Create tab group" UI, including a "Suggest more of my tabs" button featuring an icon typically indicating AI.

"Create tab group" UI, including a "Suggest more of my tabs" button featuring an icon typically indicating AI.

The UI when you click the button. Showing "Nightly uses AI to read your open tabs' titles and descriptions to suggest more tabs and group names. This happens on your device".

There are "cancel" and "continue" buttons, along with a link to customise AI settings.

The UI when you click the button. Showing "Nightly uses AI to read your open tabs' titles and descriptions to suggest more tabs and group names. This happens on your device". There are "cancel" and "continue" buttons, along with a link to customise AI settings.

Taking, for example, the tab grouping and naming feature, if you don't "Block AI enhancements", then you're offered the feature, and if you click the button, the use of AI is explained, and you have to confirm.

If you confirm, then the local privacy-preserving model is downloaded and used.

03.03.2026 14:36 πŸ‘ 3 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

AI controls landed in Firefox 148, allowing you to control each feature individually, or block them all, and any future AI features.

Without the block active, AI features are offered, but don't run without confirmation steps.

03.03.2026 14:36 πŸ‘ 2 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

Depends on the complexity. Those are really heavy dependencies, and in many cases the Web Animation API is good enough.

03.03.2026 10:28 πŸ‘ 0 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0

With CSS properties + shape(), you can animate the different points independently (as mentioned in the video). Is that possible with SVG along? I know you can animate from one path to another, but can individual points be animated in different ways?

03.03.2026 10:11 πŸ‘ 1 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

hah, yeah, I mean shape-outside. CSS shape & SVG path can make the same curves, but it's the interaction with CSS units, functions, and animations (as in the video) where things get interesting.

03.03.2026 09:44 πŸ‘ 1 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

In addition to the reasons given in the video, shapes can be used for other CSS features like offset-path and shape-around.

03.03.2026 09:10 πŸ‘ 1 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0
Path to CSS Shape Convert SVG path data to CSS shape() function.

Ohh this SVG path to CSS shape() convertor (by @matthewmorete.com) is better, as it lets you control the viewbox path-to-shape.netlify.app

03.03.2026 08:14 πŸ‘ 6 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Heart CSS shape

Here's the heart demo random-stuff.jakearchibald.com/heart-css-sh...

Note that the :hover applies to a wrapper, otherwise the clipped area is used for hit-testing - an old gotcha reminiscent of the Flash days.

02.03.2026 17:52 πŸ‘ 7 πŸ” 1 πŸ’¬ 2 πŸ“Œ 0

The difference between shape() and polygon() is that shape() can do curves, whereas polygon() can only do straight lines.

02.03.2026 17:03 πŸ‘ 1 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

Do you have a demo or something that uses path() and calc()? I'm not aware of how they can be used together. Other things like polygon() can, but I didn't think path() could.

02.03.2026 15:32 πŸ‘ 2 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0
Preview
shape() - CSS | MDN The shape() CSS function is used to define a shape for the clip-path and offset-path properties. It combines an initial starting point with a series of shape commands that define the path of the…

The full docs on MDN developer.mozilla.org/en-US/docs/W...

And a handy tool to convert SVG paths css-generators.com/svg-to-css/

02.03.2026 15:07 πŸ‘ 10 πŸ” 1 πŸ’¬ 1 πŸ“Œ 0
Video thumbnail

CSS shape() landed in Firefox 148. It's similar to path(), but allows the full expressiveness of CSS…

02.03.2026 15:07 πŸ‘ 151 πŸ” 24 πŸ’¬ 8 πŸ“Œ 3

I just did a search on the site in Firefox Nightly. I had to complete three CAPTCHAs, but then it worked.

02.03.2026 08:56 πŸ‘ 0 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0

Pulled separately from a Firefox CDN, and yes it's checked for updates. Bundling it with the browser definitely wouldn't seem opt-in.

27.02.2026 09:07 πŸ‘ 1 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
The UI as before, but with no button to suggest other tabs. The entry point has been removed.

The UI as before, but with no button to suggest other tabs. The entry point has been removed.

If you have blocked AI enhancements, this is the same UI - the entry point to the feature isn't there.

And of course, any already-downloaded models are deleted.

27.02.2026 08:47 πŸ‘ 0 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
"Create tab group" UI, including a "Suggest more of my tabs" button featuring an icon typically indicating AI.

"Create tab group" UI, including a "Suggest more of my tabs" button featuring an icon typically indicating AI.

The UI when you click the button. Showing "Nightly uses AI to read your open tabs' titles and descriptions to suggest more tabs and group names. This happens on your device".

There are "cancel" and "continue" buttons, along with a link to customise AI settings.

The UI when you click the button. Showing "Nightly uses AI to read your open tabs' titles and descriptions to suggest more tabs and group names. This happens on your device". There are "cancel" and "continue" buttons, along with a link to customise AI settings.

Taking, for example, the tab grouping and naming feature, if you don't "Block AI enhancements", then you're offered the feature, and if you click the button, the use of AI is explained, and you have to confirm.

If you confirm, then the local privacy-preserving model is downloaded and used.

27.02.2026 08:47 πŸ‘ 0 πŸ” 0 πŸ’¬ 2 πŸ“Œ 0
Preview
Making WebAssembly a first-class language on the Web – Mozilla Hacks - the Web developer blog This post is an expanded version of a presentation I gave at the recent WebAssembly CG meeting in Munich. WebAssembly has come a long way since its first release in 2017. The 1.0 version of…

WebAssembly is a second-class language on the web, but how can we make it first-class? WebAssembly Components could be the answer…

hacks.mozilla.org/2026/02/maki...

26.02.2026 16:08 πŸ‘ 60 πŸ” 11 πŸ’¬ 1 πŸ“Œ 2

It feels doable, but I don't think there's one right now that conforms to the modern spec.

25.02.2026 15:01 πŸ‘ 2 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Preview
HTML Sanitizer API - Web APIs | MDN The HTML Sanitizer API allows developers to take strings of HTML and filter out unwanted elements, attributes, and other HTML entities when they are inserted into the DOM or a shadow DOM.

Here are the full docs developer.mozilla.org/en-US/docs/W...

25.02.2026 12:09 πŸ‘ 13 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Video thumbnail

You can throw away innerHTML and replace it with the new setHTML(), which has a built-in sanitizer. Here's how it works:

25.02.2026 12:09 πŸ‘ 155 πŸ” 25 πŸ’¬ 6 πŸ“Œ 7

The article has 7 links to MDN

25.02.2026 08:58 πŸ‘ 1 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Preview
Goodbye innerHTML, Hello setHTML: Stronger XSS Protection in Firefox 148 – Mozilla Hacks - the Web developer blog Cross-site scripting (XSS) remains one of the most prevalent vulnerabilities on the web. The new standardized Sanitizer API provides a straightforward way for web developers to sanitize untrusted…

The Sanitizer API landed in Firefox 148, along with element.setHTML().

This lets you fully configure how HTML strings are cleaned as they're parsed.

hacks.mozilla.org/2026/02/good...

24.02.2026 14:18 πŸ‘ 203 πŸ” 58 πŸ’¬ 1 πŸ“Œ 14
Preview
Firefox 148 release notes for developers (Stable) - Mozilla | MDN This article provides information about the changes in Firefox 148 that affect developers. Firefox 148 was released on February 24, 2026.

Firefox 148 is out now, and adds some great web platform features:

πŸŽ‰ The HTML Sanitizer API
πŸŽ‰ CSS shape()
πŸŽ‰ Trusted Types
πŸŽ‰ Nav API's addHandler
πŸŽ‰ Iterator zip & zipKeyed
πŸŽ‰ ancestorOrigins

And more!

developer.mozilla.org/en-US/docs/M...

24.02.2026 14:10 πŸ‘ 98 πŸ” 20 πŸ’¬ 2 πŸ“Œ 2

To use your "onions" metaphor, the flow for tab grouping is:

Firefox: Do you want tab grouping?
User: Ok
Firefox: It contains onions. Do you want it? Cancel/continue.

Whereas the AI controls lets you remove everything from the menu that contains onions.

17.02.2026 13:15 πŸ‘ 2 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

I assume that you don't consider the "suggest more of my tabs" flow opt-in (a button click, an explanation, and an confirmatory button click).

What would need to change about it for it to count as opt-in for you?

17.02.2026 12:46 πŸ‘ 0 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

Of course, "suggest more of my tabs" isn't there if you've disabled that feature (or all AI features) in AI controls.

17.02.2026 12:32 πŸ‘ 0 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0