jsdom
31.0.1 · 13 Nov 2026MIT166.8M / weekRepositoryHomepagenpmAtom feed
9.12.0 is the newest release of 9.x.
In short
7 new1 faster3 fixed1 changed
Release note
Added a somewhat-reasonable implementation of focus and focus events. Although the full complexity of focus is not implemented, the following improvements have been made:
Only elements which are focusable can be focused.
Added the
FocusEventclass, and nowfocusandblurevents are fired appropriately.tabIndexnow returns0by default for focusable elements.
Reimplemented
navigatorto be to-spec:Added
appCodeName,product,productSub,vendor, andvendorSub; also changesuserAgent,appName,platform, andversionto be more browser-like instead of based on various Node.js information.Added
languageandlanguages.Added
onLine.Added
javaEnabled().Removed
noUI.
Fixed
formEl.actionto return a value resolved relative to the document URL, or to return the document URL if the corresponding attribute is missing or empty.Sped up XPath execution.
Fixed
window.close()not correctly clearing event listeners on the document.Fixed a regression introduced in v9.0.0 where invalid CSS would cause a crash while attempting to parse it. Instead, a
"jsdomError"will now be emitted to the virtual console.
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.