Open
Conversation
Snyk has created this PR to upgrade jsdom from 23.2.0 to 28.1.0. See this package in npm: jsdom See this project in Snyk: https://app.snyk.io/org/contentstack-devex/project/7a549652-4fc7-484f-b6bd-0bf453540d60?utm_source=github&utm_medium=referral&page=upgrade-pr
🔒 Security Scan Results
⏱️ SLA Breach Summary
ℹ️ Vulnerabilities Without Available Fixes (Informational Only)The following vulnerabilities were detected but do not have fixes available (no upgrade or patch). These are excluded from failure thresholds:
✅ BUILD PASSED - All security checks passed |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Snyk has created this PR to upgrade jsdom from 23.2.0 to 28.1.0.
ℹ️ Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project.
The recommended version is 21 versions ahead of your current version.
The recommended version was released a month ago.
Release notes
Package name: jsdom
-
28.1.0 - 2026-02-15
- Added
- Improved
- Improved synchronous
- Improved performance of
- Fixed
- Fixed
- Fixed
- Fixed
- Fixed a potential hang when synchronous
- Fixed compatibility with environments where Node.js's built-in
-
28.0.0 - 2026-02-02
- Overhauled resource loading customization. See the new README for details on the new API.
- Added MIME type sniffing to
- Regression:
- Fixed decoding of the query components of
- Fixed
- Fixed the referrer of a document to be set correctly when redirects are involved; it is now the initiating page, not the last hop in the redirect chain.
- Fixed correctness bugs when passing
- Fixed
- Fixed
- Fixed many small issues in
-
27.4.0 - 2025-12-26
- Added
- Improved decoding of HTML bytes by using the new
- Improved decoding of XML bytes to use UTF-8 more often, instead of sniffing for
- Fixed a memory leak when
-
27.3.0 - 2025-12-08
- Improved CSS parsing and CSSOM object APIs via updates to
-
27.2.0 - 2025-11-12
- Added
- Improved CSS parsing and CSSOM object APIs via updates to
- Fixed
-
27.1.0 - 2025-10-31
- Improved CSS parsing by switching to
- Fixed some selector cache invalidation issues where changes to attributes were not being picked up. (@ asamuzaK)
- Fixed
-
27.0.1 - 2025-10-18
- Fixed some regressions in CSS selectors. Most such regression fixes were done in a minor update of a dependency, and thus available for all fresh installs of v27.0.0. However, one related to
-
27.0.0 - 2025-09-13
- Node.js v20 is now the minimum supported version.
- Added a variety of event constructors, even though we do not implement their associated specifications or ever fire them:
- Added
- Added
- Updated the virtual console:
- The
- The values that are printed when forwarding
- Switched our CSS selector engine from
- Upgraded
- Upgraded
- Updated the user agent stylesheet to be derived from the HTML Standard, instead of from an old revision of Chromium.
- Changed
- Changed certain events to be passive by default.
- Changed the
- Fixed many specification conformance issues with the
- Fixed
- Fixed the
- Fixed using
- Fixed
- Fixed CSS system colors, as well as the
- Fixed CSS
- Upgraded
-
27.0.0-beta.3 - 2025-08-31
- Breaking change: upgraded
- Added
- Changed the
- Fixed
- Fixed CSS system colors, as well as the
- Fixed CSS
- Fixed CSS color parsing and serialization inside of gradients. (@ asamuzaK)
- Fixed CSS
- Upgraded
-
27.0.0-beta.2 - 2025-06-08
-
27.0.0-beta.1 - 2025-05-06
-
27.0.0-beta.0 - 2025-04-19
-
26.1.0 - 2025-04-13
-
26.0.0 - 2025-01-09
-
25.0.1 - 2024-09-22
-
25.0.0 - 2024-08-25
-
24.1.3 - 2024-08-25
-
24.1.2 - 2024-08-25
-
24.1.1 - 2024-07-21
-
24.1.0 - 2024-05-26
-
24.0.0 - 2024-01-21
-
23.2.0 - 2024-01-07
from jsdom GitHub release notesblob.text(),blob.arrayBuffer(), andblob.bytes()methods.getComputedStyle()to account for CSS specificity when multiple rules apply. (@ asamuzaK)XMLHttpRequestperformance by using a persistent worker thread, avoiding ~400ms of setup overhead on every synchronous request after the first one.node.getRootNode(),node.isConnected, andevent.dispatchEvent()by caching the root node of document-connected trees.getComputedStyle()to correctly handle!importantpriority. (@ asamuzaK)document.getElementById()to return the first element in tree order when multiple elements share the same ID.<svg>elements to no longer incorrectly proxy event handlers to theWindow.FileReaderevent timing andfileReader.resultstate to more closely follow the spec.XMLHttpRequestencountered dispatch errors.fetch()has been used before importing jsdom, by working around undici v6/v7 incompatibilities.<iframe>and<frame>loads.WebSockets are no longer correctly throttled to one connection per origin. This is a result of the bug at nodejs/undici#4743.<a>and<area>elements in non-UTF-8 documents.XMLHttpRequestfetches andWebSocketupgrade requests to be interceptable by the new customizable resource loading. (Except synchronousXMLHttpRequests.)ArrayBuffers or typed arrays to various APIs, where they would not correctly snapshot the data.require("url").parse()deprecation warning when usingWebSockets.<iframe>,<frame>, and<img>(whencanvasis installed) to fireloadevents, noterrorevents, on non-OK HTTP responses.XMLHttpRequest.TextEncoderandTextDecoder.@ exodus/bytespackage; it is now much more correct. (@ ChALkeR)<meta charset>or using the parent frame's encoding.Ranges were used and then the elements referred to by those ranges were removed.@ acemir/cssom. (@ acemir)CSSGroupingRule,CSSNestedDeclarations,CSSConditionRule,CSSContainerRule,CSSScopeRule,CSSSupportsRule,CSSLayerBlockRule, andCSSLayerStatementRuleto jsdomWindows. (@ acemir)@ acemir/cssom. (@ acemir)@ import-ed stylesheets to be properly exposed to CSSOM, and not to overwrite the sheet created from the<link>or<style>element. (@ acemir)@ acemir/cssom, including support for nested selectors, nested declarations, layer statements, and improved at-rule validation. (@ acemir)package.json"engines"field to reflect the new minimum Node.js versions needed to run jsdom, as noted in the changelog for v27.0.1.This release inadvertently raised the minimum Node.js version from v20.0.0 to v20.19.0+, v22.12.0+, v24.0.0+. (This happened via a dependency update.) This probably should have been a breaking (major) change, instead of happening in a patch version, since it prevents using earlier Node.js versions.
After further testing, we found that most of our development dependencies also require these versions, and so it's not feasible for the jsdom project to support earlier Node.js versions. (For example, our testing frameworks will not run on them.) If you need to use such earlier versions, or otherwise are working in an environment which gives related errors such as
ERR_REQUIRE_ESM, then please stick with the v26.1.0 release of jsdom. (Noting, of course, that such versions are unsupported, and we will not respond to bug reports opened against them.)Subsequent jsdom releases will explicitly require these minimum Node.js versions, and will have CI testing to ensure that the minimum version is not accidentally raised again.
Normal changelog:
class=""attribute changes is only possible with a new version of jsdom. (@ asamuzaK)Changes since 26.1.0
BeforeUnloadEvent,BlobEvent,DeviceMotionEvent(omittingrequestPermission()),DeviceOrientationEvent(omittingrequestPermission()),PointerEvent,PromiseRejectionEvent, andTransitionEvent.movementXandmovementYtoMouseEvent. (These are from the Pointer Lock specification, the rest of which is not implemented.)customElements.getName(). (@ mash-graz)"jsdomError"events are now documented, with specifictypeproperties and other properties that depend on the type.sendTo()was renamed toforwardTo().jsdomErrorsoption toforwardTo()can be used to control which errors are sent to the Node.js console. This replaces the previousomitJSDOMErrorsboolean option."jsdomError"s for failedXMLHttpRequestfetches are no longer emitted."jsdomError"s to the Node.js console are streamlined.nwsapito@ asamuzakjp/dom-selector, closing over 20 selector-related bugs.tough-cookie, which now considers URLs likehttp://localhost/to be secure contexts (per the spec), and thus will returnSecure-flagged cookies for such URLs. (@ colincasey)cssstyle, which brings along many improvements and fixes to theCSSStyleDeclarationobject and its properties.element.click()to fire aPointerEventinstead of aMouseEvent.<input>element'spattern=""attribute to use thevregular expression flag, instead ofu.Windowobject, including named properties and changing various data properties to accessor properties.document.createEvent()to accept a more correct set of event names.ElementInternalsaccessibility getters and setters. (They were introduced in v23.1.0, but due to inadequate test coverage never actually worked.)Object.defineProperty()on certain objects, such asHTMLSelectElementinstances.jsdom.reconfigure({ url })not updatingdocument.baseURIor properties derived from it. (This regressed in v26.1.0.)initial,inherit, andunsetkeywords, to resolve correctly. (@ asamuzaK)displaystyle resolution. (@ asamuzaK)Changes since 27.0.0-beta.3
cssstyle, which brings along various CSS parsing fixes.tough-cookie, which now considers URLs likehttp://localhost/to be secure contexts (per the spec), and thus will returnSecure-flagged cookies for such URLs. (@ colincasey)customElements.getName(). (@ mash-graz)<input>element'spattern=""attribute to use thevregular expression flag, instead ofu.jsdom.reconfigure({ url })not updatingdocument.baseURIor properties derived from it. This regressed in v26.1.0.initial,inherit, andunsetkeywords, to resolve correctly. This is especially important since the change in v27.0.0-beta.1 to use system colors in the user agent stylesheet. (@ asamuzaK)backgroundproperty parsing and serialization. (@ asamuzaK)displaystyle resolution. (@ asamuzaK)@ asamuzakjp/dom-selector, which notably fixed repeated use of the:scopeselector. (@ asamuzaK)Significantly improved specification conformance for the
Windowobject, including named properties and changing various data properties to accessor properties. This is not likely to be breaking, but since it's a complex change to such a core object, we're happy to do another beta testing release with this included before graduating the v27 line to stable.Additionally, updated
cssstyleto v4.4.0, which brings along various conformance fixes to theCSSStyleDeclarationobject and its properties.Important
Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs.
For more information: