Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

⬆️ Updates jsdom to v24 #2357

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

⬆️ Updates jsdom to v24 #2357

wants to merge 1 commit into from

Conversation

renovate[bot]
Copy link

@renovate renovate bot commented Jan 21, 2024

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
jsdom 16.6.0 -> 24.0.0 age adoption passing confidence

Release Notes

jsdom/jsdom (jsdom)

v24.0.0

Compare Source

This release reverts our selector engine back to nwsapi. As discussed in #​3659, the performance regressions from @asamuzakjp/dom-selector turned out to be higher than anticipated. In the future, we can revisit @asamuzakjp/dom-selector after it reaches nwsapi's performance on the two real-world benchmarks provided by the community.

Since reverting to nwsapi causes several functionality regressions, e.g. removing :has() support, we've decided to make this a major version.

Additionally:

  • Small fixes to edge-case behavior of the following properties: input.maxLength, input.minLength, input.size, progress.max, tableCell.colSpan, tableCell.rowSpan, tableCol.span, textArea.cols, textArea.maxLength, textArea.minLength, textArea.rows.

v23.2.0

Compare Source

This release switches our CSS selector engine from nwsapi to @asamuzakjp/dom-selector. The new engine is more actively maintained, and supports many new selectors: see the package's documentation for the full list. It also works better with shadow trees.

There is a potential of a performance regression due to this change. In our stress test benchmark, which runs most of these 273 selectors against this 128 KiB document, the new engine completes the benchmark only 0.25x as fast. However, we're hopeful that in more moderate usage this will not be a significant issue. Any help speeding up @asamuzakjp/dom-selector is appreciated, and feel free to open an issue if this has had a significant impact on your project.

v23.1.0

Compare Source

  • Added an initial implementation of ElementInternals, including the shadowRoot getter and the string-valued ARIA properties. (zjffun)
  • Added the string-valued ARIA attribute-reflecting properties to Element.
  • Fixed history.pushState() and history.replaceState() to follow the latest specification, notably with regards to how they handle empty string inputs and what new URLs are possible.
  • Fixed the input.valueAsANumber setter to handle NaN correctly. (alexandertrefz)
  • Updated various dependencies, including cssstyle which contains several bug fixes.

v23.0.1

Compare Source

  • Fix incorrect canvas peer dependency.

v23.0.0

Compare Source

v22.1.0

Compare Source

  • Added crypto.randomUUID(). (jamesbvaughan)
  • Added DOMRect and DOMRectReadOnly.
  • Added AbortSignal.timeout().
  • Added abortSignal.throwIfAborted().
  • Added support for the submitter argument to the FormData constructor. (jenseng)
  • Improved getComputedStyle()'s results for color-based properties, to resolve named colors and attempt to provide initial inheritance support. (hoekz-wwt)
  • Updated Window's event handler properties (e.g. oncopy, ontouchstart, etc.) to reflect the latest list from the standard.
  • Fixed DOMParser-created documents to inherit their URL from the creating document.

v22.0.0

Compare Source

v21.1.2

Compare Source

  • Fixed setRangeText() used on <input> and <textarea> elements to calculate the new end index correctly. (pmstss)
  • Fixed pageX, pageY, offsetX, and offsetY on MouseEvents during dispatch. (jenseng)
  • Upgraded nwsapi to v2.2.4, bringing along various fixes to our selector engine.

v21.1.1

Compare Source

  • Fixed jsdom.reconfigure() to also adjust the URL as seen by the history API, so that e.g. history.replaceState(null, "") would not mess up the URL. (jdufresne)
  • Fixed location.hash = "" to leave any # in location.href.
  • Fixes a few bugs with CSS parsing by replacing cssom with rweb-cssom, since the latter is maintained. (seanparmelee)

v21.1.0

Compare Source

  • Added x, y, pageX, pageY, offsetX, and offsetY to MouseEvent. (jenseng, ViniciusFXavier)
  • Added support for unset with getComputedStyle(). (jsnajdr)
  • Added the submitter property to SubmitEvent. (jenseng)
  • Fixed MouseEvent's screenX and screenY to no longer coerce to integers, allowing fractional values. (jenseng)
  • Fixed formEl.submit() to not longer fire submit events. (jenseng)
  • Fixed stylesheets to no longer affect the document after their corresponding <link> is removed. (jsnajdr)
  • Fixed pointer-events to inherit when used with getComputedStyle(). (jnajdr)
  • Fixed <script> elements with no src="" to no longer fire load events. (t1ger2080)
  • Improved getComputedStyle() to cache its results, which should make it much faster. (jsnajdr)

v21.0.0

Compare Source

A potentially-breaking bug fix:

  • Fixed the window, document, location, and top properties of Window to be non-configurable. (ExE-Boss)

Other changes:

  • Added support for <input type=image> submitting forms. (jenseng)
  • Added the location setter to the Window object, which forwards to the location.href setter. Setting the URL is still only implemented for fragment navigations, however. (ExE-Boss)
  • Fixed defer="" <script> elements that are added after DOMContentLoaded to execute, instead of being skipped.
  • Fixed selectElement.selectedOptions being incorrect when optionElement.selected is set. This was a regression introduced in v20.0.1. Unfortunately this also reverts the performance improvement when appending <option> elements that was introduced then. (eps1lon)
  • Fixed the self, locationbar, menubar, personalbar, scrollbars, statusbar, toolbar, frames, parent, external, length, and screen properties of Window to be replaceable: that is, setting them will override their values, instead of having the new value be ignored. (ExE-Boss)
  • Fixed a few issues with JSDOM.fromURL() in the browser build of jsdom. (LungZeno)

v20.0.3

Compare Source

  • Updated dependencies, notably w3c-xmlserializer, which fixes using DOMParser on XML documents containing emoji.

v20.0.2

Compare Source

  • Fixed xhr.abort() to no longer give an exception when the constructed XMLHttpRequest was invalid. (whamtet)
  • Fixed event.getModifierState() on MouseEvent and KeyboardEvent instances to properly consult the ctrlKey, altKey, metaKey, and shiftKey properties of the event. (juzerzarif)
  • Fixed custom element creation to not be affected by any modifications to the window.customElements property. (bicknellr)

v20.0.1

Compare Source

  • Improved the performance of appending <option> elements to <select> elements. (TheHound)
  • Fixed location.pathname getter to not crash when the JSDOM instance was created using an opaque-path URL, including the default URL of about:blank.
  • Fixed crypto.getRandomValues() to accept typed array subclasses. (sebamarynissen)
  • Updated various dependency minor versions. Notably, nwsapi fixed some selectors bugs, and tough-cookie fixed some cookie bugs.

v20.0.0

Compare Source

  • Node.js v14 is now the minimum supported version.
  • Added crypto.getRandomValues(). (sjrd)
  • Added HTMLFormControlsCollection and RadioNodeList, so formEl.elements now behaves correctly. (UndefinedBehavior)
  • Added the signal option to addEventListener(). (cheap-glitch)
  • Fixed the :root pseudoclass to work correctly. (hughs-ch)
  • Updated parse5, bringing along some HTML parsing and serialization fixes. (fb55)

v19.0.0

Compare Source

  • Changed jsdom.nodeLocation() to return undefined when used on nodes that originate via fragment parsing (e.g., via innerHTML). Previously it would return based on the node location of the fragment string, which made node locations unreliable with respect to the original document source. This restores the behavior that was present in v14.0.0, and was accidentally broken in v14.1.0. (bakkot)
  • Fixed calling window.close() inside the Window's load event to no longer crash. (MattiasBuelens)

v18.1.1

Compare Source

  • Fixed connectedCallback to fire in situations involving document fragments, which was broken in v18.0.1. (GrantGryczan)

v18.1.0

Compare Source

  • Fixed headers.append() and headers.set() to normalize values. (MattiasBuelens)
  • Fixed pageshow events to have bubbles: true and cancelable: true. (MattiasBuelens)
  • Implemented the reason property on AbortSignals, along with the corresponding reason argument to abortSignal.abort() and AbortSignal.abort(). (MattiasBuelens)

v18.0.1

Compare Source

  • Fixed live Ranges to update correctly after calling node.normalize(). (hgiesel)
  • Fixed live Ranges to update correctly after removing child nodes. (hgiesel)
  • Fixed setting inputEl.valueAsDate = null to no longer throw an exception, but instead set the value to the empty string. (simon-weimann)
  • Improved performance of node insertion and node.contains(). (GrantGryczan)

v18.0.0

Compare Source

Potentially-breaking bug fixes:

  • Fixed SSL certificate checking for WebSocket connections. Previously, invalid SSL certificates were always accepted; now, they properly respect the ResourceLoader's strictSSL option (which defaults to true).
  • Changed the global in which almost all Promise and TypeError instances are created to be the jsdom global, not the Node.js global. This could affect any code that uses instanceof.

Other changes:

  • Fixed moving an element between HTML and XML documents to reset the tagName cache, allowing it to return a lowercase value once it's in the XML document. (LucasLefevre)
  • Fixed form submission to not happen when the form is invalid. (pozil)

v17.0.0

Compare Source

Breaking change: Node v12 is now the minimum supported version.

v16.7.0

Compare Source

  • Added AbortSignal.abort(). (ninevra)
  • Added dummy x and y properties to the return value of getBoundingClientRect(). (eiko)
  • Implemented wrapping for textareaEl.value if the wrap="" attribute is specified. (ninevra)
  • Changed newline normalization in <textarea>s according to recent HTML Standard updates. (ninevra)
  • Fixed some bad cascade computation in getComputedStyle(). (romain-trotard)

Configuration

📅 Schedule: Branch creation - "after 10pm every weekday,before 5am every weekday,every weekend" in timezone Europe/Moscow, Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Copy link
Author

renovate bot commented Jan 21, 2024

Branch automerge failure

This PR was configured for branch automerge. However, this is not possible, so it has been raised as a PR instead.


  • Branch has one or more failed status checks

Copy link

Thanks for opening an issue! Make sure you've followed CONTRIBUTING.md.

Copy link

Hello from PR Helper

Is your PR ready for review and processing? Mark the PR ready by including #pr-ready in a comment.

If you still have work to do, even after marking this ready. Put the PR on hold by including #pr-onhold in a comment.

Copy link

Thanks for the PR!

This section of the codebase is owner by https://github.com/AlexRogalskiy/ - if they write a comment saying "LGTM" then it will be merged.

Copy link

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/jsdom@24.0.0 eval, filesystem, network, shell, unsafe Transitive: environment +90 9.77 MB domenic

🚮 Removed packages: npm/jsdom@16.6.0

View full report↗︎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

0 participants