Skip to Content
  • Home
  • Blog
  • Privacy Policy
  • Terms And conditions
  • Disclaimer
  • About Us
      • Home
      • Blog
      • Privacy Policy
      • Terms And conditions
      • Disclaimer
      • About Us
  • Knowledge Base
  • MDN Documentation Updates: New CSS :nth-child() of‑selector, Media Features, and Web API Additions
  • MDN Documentation Updates: New CSS :nth-child() of‑selector, Media Features, and Web API Additions

    24 February 2026 by
    Suraj Barman

    MDN Documentation Updates

    MDN has refreshed a range of reference pages to reflect recent browser implementations. The updates introduce the of selector for :nth-child() and :nth-last-child(), broaden support for several media features, add detailed coverage of emerging Web APIs, and document module loading capabilities in workers. Compatibility tables and code snippets illustrate practical usage.

    CSS Pseudo‑class Enhancements

    The of selector extends the classic positional matching of :nth-child() and :nth-last-child(). By appending an of clause, developers can narrow the selection to elements that also match a secondary selector, enabling patterns such as targeting only highlighted list items within a broader positional rule.

    Syntax Overview

    ```css li:nth-child(-n+3 of .important) { / styles for the 2nd and 5th items / } ``` The expression follows the familiar An+B format, with the optional of <selector> component appended after the arithmetic portion.

    Browser Availability

    Support is currently limited to Firefox and Safari. Developers should provide fallbacks for browsers that lack this capability.

    Expanded Media Feature Support

    Several media queries have moved from experimental to supported status in Firefox, broadening the toolbox for responsive design.

    prefers‑reduced‑transparency

    This feature detects a user preference to limit transparent overlays. Example usage:
    @media (prefers-reduced-transparency) { .panel { opacity:0.9 } }

    :lang() string‑matching

    The :lang() pseudo‑class now accepts comma‑separated language lists and wildcard matching, allowing patterns such as :lang("nl","de") to style elements for multiple locales.

    Web API Additions and Updates

    MDN has added comprehensive reference material for emerging web standards, including the WebGPU rendering interface and the WebTransport communication API. These pages detail constructors, methods, and error handling patterns.

    WebGPU Overview

    The WebGPU API documentation now describes pipeline creation, buffer mapping, and device error scopes, with notes on current browser flags.

    WebTransport Enhancements

    New constructor options—allowPooling, requireUnreliable, and congestionControl—and properties such as reliability and draining are documented. The WebTransport page includes usage examples for low‑latency data streams.

    Compression Streams API

    The API now lists supported compression methods (gzip, deflate, deflate‑raw) within the CompressionStream and DecompressionStream objects, enabling developers to process binary data directly in the browser.

    ECMAScript Module Loading in Workers

    Firefox adds static import support for dedicated, shared, and service workers, as well as static imports in worklets. Dynamic import() remains prohibited in service workers per the specification, encouraging explicit module graphs.


    Latest Stories

    Explore fresh ideas and updates from our editorial team.

    See All
    Your Dynamic Snippet will be displayed here... This message is displayed because you did not provide enough options to retrieve its content.

    Copyright © 2026 TechStora. All Rights Reserved.