npm jsdom 12.0.0
Version 12.0.0

latest releases: 24.0.0, 23.2.0, 23.1.0...
5 years ago

This major release brings along our new resource loader API, finally bringing all the capabilities from jsdom v9 to the new (jsdom v10+) API. Thanks very much to @sarvaje for his work to make this possible!

Breaking changes:

  • jsdom now requires Node.js v8.
  • Removed the old jsdom API, as the new API now has all the capabilities you need.
  • Updated our parse5 dependency to v5, which changes the format of the node locations returned by dom.nodeLocation().
  • Updated our whatwg-url dependency to v7, which changes the origin of file: URLs to be an opaque origin (and thus file: URLs are no longer same origin to each other).

Other changes:

  • Added countReset(), dir() and dirxml() methods to console.
  • Added the InputEvent class.
  • Added window.status.
  • Added htmlElement.draggable.
  • Fixed window.frameElement to correctly return an actual HTMLElement instance, instead of a jsdom internal class.
  • Fixed cloning of textarea elements to preserve their values.
  • Fixed select.selectedOptions sometimes returning outdated results.
  • Fixed CSS selection APIs sometimes returning outdated results, especially for state pseudo-class selectors like :checked.
  • Fixed CSS selection APIs to throw an error for invalid selectors even when used on empty nodes.
  • Fixed window.name to default to the empty string, per spec, instead of "nodejs".
  • Fixed the default User-Agent to say "unknown OS" instead of "undefined" when jsdom is used in web browsers.

Don't miss a new jsdom release

NewReleases is sending notifications on new releases.