unstale

npm / @happy-dom/global-registrator

@happy-dom/global-registrator

What changed in @happy-dom/global-registrator 20 to 21, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-18.

4 breaking5 security1 deprecations17 new APIs and options8 performance9 behavior and defaults65 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

@happy-dom/global-registrator 213 changes

Breaking changes 1

  • CSS and IFrame loading are disabled by default to prevent server-side request forgery from untrusted HTML.

    21.0.0release notes

Security 1

  • Fixes a security vulnerability where the authorization header was forwarded when redirecting.

    21.0.3release notes

Deprecations 1

  • The settings property disableCSSFileLoading has been deprecated.

    21.0.0release notes

@happy-dom/global-registrator 20106 changes

Breaking changes 3

  • Cookies from the current origin are no longer forwarded to the target origin in fetch requests.

    20.8.9release notes

  • Throws an error if the event passed to EventTarget.dispatchEvent() is not of type Event.

    20.8.3release notes

  • The inert attribute now blocks focus interactions.

    20.8.1release notes

Security 4

  • Fixes a cookie scope forgery vulnerability.

    20.14.6release notes

  • Values pushed or assigned to the adoptedStyleSheet array are validated.

    20.11.8release notes

  • Fixes executable-code interpolation in ESM export names that could allow escaping the VM context and accessing process-level functionality in unsafe CommonJS environments.

    20.8.8release notes

  • EventTarget no longer calls arbitrary on* properties.

    20.3.4release notes

New APIs and options 17

  • Adds support for the :host pseudo query selector.

    20.13.0release notes

  • Adds support for Animation.

    20.12.0release notes

  • Adds support for AnimationTimeline.

    20.12.0release notes

  • Adds support for DocumentTimeline.

    20.12.0release notes

  • Adds support for Element.animate().

    20.12.0release notes

  • Adds support for KeyframeEffect.

    20.12.0release notes

  • Allows specifying an explicit element type for querySelector results, such as HTMLInputElement.

    20.11.5release notes

  • Adds support for event listener properties on Window, such as Window.onkeydown.

    20.9.0release notes

  • Adds support for hasPointerCapture to Element.

    20.8.0release notes

  • Adds support for releasePointerCapture to Element.

    20.8.0release notes

  • Adds support for setPointerCapture to Element.

    20.8.0release notes

  • Adds support for Window.getScreenDetails().

    20.7.0release notes

  • Adds support for registering globals when importing the package.

    20.6.0release notes

  • Implements the Text.wholeText property.

    20.5.4release notes

  • Adds the which property to KeyboardEvent.

    20.3.3release notes

  • Adds support for CloseEvent, making it available to developers using Happy DOM.

    20.1.0release notes

  • Adds support for WebSocket, making it available to developers using Happy DOM.

    20.1.0release notes

Performance 8

  • The computed style cache is improved, which may improve performance.

    20.14.0release notes

  • Query selector performance is improved by avoiding DOMException construction when it is not needed.

    20.11.1release notes

  • Adds a cache to mitigate the selector parser's performance degradation introduced in v20.6.3.

    20.10.5release notes

  • Adds support for caching compiled EcmaScript module code.

    20.4.0release notes

  • Improves how nodes are destroyed and garbage collected.

    20.4.0release notes

  • Adding and removing tokens is optimized with a Set.

    20.3.2release notes

  • Query selectors use Element.classList.contains() instead of splitting className, improving performance because classList is cached.

    20.2.0release notes

  • Avoids sorting in querySelector() to improve performance.

    20.1.1release notes

Behavior and default changes 9

  • Adds support for kebab-case properties on CSSStyleDeclaration.

    20.12.1release notes

  • Adds support for all Chromium CSS properties to CSSStyleDeclaration.

    20.12.1release notes

  • Adds support for loading image data URLs.

    20.10.0release notes

  • Screen now extends EventTarget.

    20.7.0release notes

  • The query selector parser can handle complex rules.

    20.6.3release notes

  • CSS gradients now support rgba().

    20.6.1release notes

  • HTML/XML encoding and decoding now uses the entities package.

    20.5.2release notes

  • Elements are upgraded to custom elements only when they are in the document, which also improves memory footprint by allowing nodes to be garbage collected before the document is closed.

    20.0.9release notes

  • Workers in @happy-dom/server-renderer now use the frozen intrinsics flag.

    20.0.2release notes

Fixes and other changes 65

  • Character references are preserved in comment data.

    20.14.5release notes

  • End comments at the first comment end tag when it overlaps a comment start tag.

    20.14.4release notes

  • Fixes a regression where not all CSS variables were resolved in getComputedStyle().

    20.14.2release notes

  • Invalidates the computed style cache for the whole subtree.

    20.14.1release notes

  • Fixes getComputedStyle with :host and :host-context selectors.

    20.13.2release notes

  • GetComputedStyle now returns the inherited value when a property is set to inherit.

    20.13.1release notes

  • Custom elements are upgraded when connected to the DOM.

    20.12.2release notes

  • Fixes issue with parsing CSS fallback variables.

    20.12.1release notes

  • Fixes an issue with upgrading custom elements caused by the previous release.

    20.11.15release notes

  • Upgrading an element changes its prototype to the custom element, keeping references to the original element valid.

    20.11.14release notes

  • Event listeners are copied when upgrading a custom element.

    20.11.13release notes

  • Adds a check that a node is still a parent during disconnect.

    20.11.12release notes

  • Returns the default validationMessage for built-in constraint violations.

    20.11.10release notes

  • Ensures an element has been upgraded before invoking its reaction callback.

    20.11.9release notes

  • Document.adoptedStyleSheets and ShadowRoot.adoptedStyleSheets now validate their value.

    20.11.7release notes

  • The CORS check in fetch() now matches origins instead of host and protocol.

    20.11.4release notes

  • document.links now returns a live HTMLCollection.

    20.11.3release notes

  • Copies the labels array to prevent mutation of a cached querySelectorAll result.

    20.11.3release notes

  • Fixes the callback being garbage-collected due to an orphaned WeakRef.

    20.11.2release notes

  • Awaits the NodeJS internal ReadableStream promise during teardown.

    20.10.6release notes

  • A null qualifiedName is coerced to an empty string in createDocument.

    20.10.4release notes

  • Fixes attribute selector matching for hyphenated substrings in CSS selectors.

    20.10.3release notes

  • Replaces implementation of Node.js Console with the common IConsole interface to support the latest version of Bun.

    20.8.7release notes

  • Request.formData() now honors the Content-Type header.

    20.8.6release notes

  • Fixes an error thrown when modifying DOM structure in connectedCallback().

    20.8.5release notes

  • Calling Event.initEvent() resets Event.cancelBubble and Event.defaultPrevented.

    20.8.2release notes

  • CSS escape sequences in attribute selector values are now properly decoded.

    20.7.2release notes

  • Fixes parsing of direct descendant (>) and universal (*) query selectors.

    20.7.1release notes

  • Adds clearImmediate to the Jest environment's global scope.

    20.6.5release notes

  • Invalid input type attributes are normalized to text per the HTML specification.

    20.6.4release notes

  • Fixes query selectors for attributes in XML documents.

    20.6.3release notes

  • Fixes attribute query selectors with quotes inside quoted values.

    20.6.3release notes

  • Resolves a missing export affecting Vue and vue-compat v3.5.

    20.6.2release notes

  • Selectors now support unicode characters per the CSS spec.

    20.6.1release notes

  • Corrects the caption element content model to allow flow content.

    20.5.5release notes

  • Node.replaceWith no longer throws when called without a parent.

    20.5.3release notes

  • Fixed logic to make HTMLInputElement.stepDown() work according to spec.

    20.5.1release notes

  • Fixed logic to make HTMLInputElement.stepUp() work according to spec.

    20.5.1release notes

  • Selection API now accepts Document nodes as valid boundary points.

    20.3.9release notes

  • Fixed the getters for focusNode and focusOffset, which returned incorrect values.

    20.3.8release notes

  • Fixes toggling the open attribute of <details> by clicking a child of <summary>.

    20.3.6release notes

  • Checks whether hostname and pathname are undefined using optional chaining.

    20.3.5release notes

  • Preserves attribute name case in CSS selectors for XML documents.

    20.3.4release notes

  • Implements implicit closing of <p> elements per the HTML spec.

    20.3.4release notes

  • Parses the Cache-Control header max-age value with parseFloat().

    20.3.3release notes

  • Fixes Node.contains() for <select> and <form> elements.

    20.3.3release notes

  • Returns the correct root for detached shadow trees.

    20.3.3release notes

  • Named HTML entities are decoded correctly.

    20.3.2release notes

  • WebSocket URLs can include paths.

    20.3.2release notes

  • Normalizes the format parameter according to the HTML specification.

    20.3.1release notes

  • Handles partial responses.

    20.3.1release notes

  • Fixes caching in querySelector().

    20.1.1release notes

  • Manually set authorization headers are now included in requests; headers are omitted only when automatically set by page context.

    20.0.11release notes

  • Closing a Window now clears event listeners on all nodes to prevent memory leaks.

    20.0.10release notes

  • nextSibling() now works in HTMLSelectElement and HTMLFormElement.

    20.0.8release notes

  • previousSibling() now works in HTMLSelectElement and HTMLFormElement.

    20.0.8release notes

  • Parsing an item without a permitted parent, such as <tr>, is valid inside a <template> element.

    20.0.8release notes

  • Fixes incorrect handling of the >= operator in the media query parser.

    20.0.7release notes

  • Changes the implementation to be spec compliant.

    20.0.6release notes

  • Changes the implementation to be spec compliant.

    20.0.6release notes

  • Changes the implementation to be spec compliant.

    20.0.6release notes

  • The setter now validates that the value is a Node.

    20.0.5release notes

  • Buttons are added to FormData only if they are the submitter.

    20.0.4release notes

  • CSS variables are now parsed correctly when they appear inside CSS functions.

    20.0.3release notes

  • URL resolution now occurs after checking whether module preloading is enabled, preventing URL errors when a URL cannot be resolved.

    20.0.3release notes