Drupal core has changed jQuery once() [Drupal 10 compatibility]

Created on 9 January 2023, over 1 year ago
Updated 25 September 2023, 9 months ago

Drupal core has removed jQuery dependency from the once feature but this method is still used by DataTables and prevents from going on with adding support for Drupal 10 core compatibility. Need to be changed by following the given instructions from the Drupal core change record . So the datatables.libraries.yml and datatables.js files need to be modified on this regard like the following:

  • In datatables.js the following part:
    • $(selector, context).once('datatables').each(function () {
  • should be changed to:
    • $(once('datatables', selector, context)).each(function () {
  • In datatables.libraries.ymlthe following part:
    • - core/jquery.once
  • should be changed to
    • - core/once
📌 Task
Status

Fixed

Version

2.0

Component

Code

Created by

🇫🇷France Chris64 France

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024