v150 · platform hygiene

Remove [LegacyNoInterfaceObject] from FontFaceSet IDL

FontFaceSet becomes a real global. Chromium's IDL accidentally carried [LegacyNoInterfaceObject], hiding the interface object on window and dropping constructor from its prototype. Removing the annotation matches the CSS Font Loading spec and what Safari and Firefox have shipped all along.

concepts

  1. FontFaceSet Probe

    Reports whether FontFaceSet is present on window, whether document.fonts is an instanceof FontFaceSet, and whether its constructor.name exposes the right value.

  2. Worker Exposure

    The other half of [Exposed=(Window,Worker)]. Runs the same identity probes inside a dedicated Worker and surfaces the result — the worker-side fix is easy to forget when sanity-checking from window scope only.

  3. Prototype Inspector

    Walks the FontFaceSet prototype chain and verifies every surface [LegacyNoInterfaceObject] was hiding: window.FontFaceSet presence, instanceof check, constructor.name, own-property list, and a live worker-side probe — all in one page.

  4. Set-like Iteration Demo

    Exercise every Set-like method on document.fonts with live buttons: .size, .has(), .forEach(), .values(), .keys(), .entries(), for…of, and instanceof FontFaceSet. Add synthetic FontFace objects first to give the iterators something to iterate over.

  5. Dynamic Font Loader

    Add, inspect, and remove FontFace objects from document.fonts via a form — choose family, weight, and style, then click Add. The live table reflects document.fonts.size, each font's status, and whether document.fonts instanceof FontFaceSet holds in Chrome 150+. Includes document.fonts.ready and document.fonts.check() test buttons.

  6. FontFaceSet Migration Guide

    Live probe of all FontFaceSet capabilities with before/after code panels. Toggles between the legacy document.fonts.add() pattern and the new new FontFaceSet([]) constructor, shows a full interface comparison table, and runs a real Worker font loading probe to confirm both Window and Worker exposure work in Chrome 150+.

why it shipped

This is one of those tiny interop fixes that has a long tail of real consequences. Libraries that feature-detect FontFaceSet on window would think Chrome didn't support it, and code that walked document.fonts.constructor got undefined. The spec never asked for this and other browsers don't do it; the annotation was a historical accident in Chromium's IDL. Removing it makes FontFaceSet a normal constructible-shaped global like every other DOM interface.

references

implementation reference

Need the exact API surface, compatibility boundaries, errors, lifecycle, and source links? Read the matching gendn reference ↗