Add checks to detect jQuery 4 incompatibilities ahead of WordPress 7.2 / 7.3
Los mantenedores suelen responder en 1 día
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 38/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- javascript, jquery, php, wordpress
- Área
- developer-experience, testing
Línea de trabajo
Start by reading the existing React 19 compatibility check (#1356) and the check registration and test patterns it uses. Confirm the proposed API list against the jQuery 4.0 upgrade guide, then identify where plugin JavaScript and inline scripts are scanned. Done means the warning check is registered and documented, reports file, line, and replacement links, and has passing and failing fixtures with minified or vendored file behavior covered.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Background
WordPress 7.2 will ship with jQuery Migrate 3.6.0 to prepare for updating to jQuery 4 in core. The planned timeline, per Preparing for jQuery 4 with WordPress 7.2:
- WordPress 7.2: update jQuery Migrate to 3.6.0, so extenders can catch deprecation notices.
- WordPress 7.3 (tentative): update to the latest jQuery and jQuery Migrate, plus jQuery UI and other jQuery-dependent libraries.
- End of 2027 (WordPress 7.5 or 7.6): disable jQuery Migrate by default.
Progress is tracked in core ticket #60478.
Once Migrate is disabled by default, plugins that rely on APIs removed in jQuery 4 will break on the front end and in the admin. Plugin Check is well placed to help developers find these issues before submission.
Proposal
Add a static check, for example jquery_deprecated_apis, that scans plugin JS (and inline scripts where feasible) for jQuery APIs removed or deprecated in jQuery 4. Suggested starting list, to be confirmed against the jQuery 4.0 upgrade guide:
- Removed utilities:
jQuery.isArray,jQuery.parseJSON,jQuery.trim,jQuery.type,jQuery.now,jQuery.isNumeric,jQuery.isFunction,jQuery.isWindow,jQuery.camelCase,jQuery.nodeName - Removed or deprecated events and methods:
.bind(),.unbind(),.delegate(),.undelegate(),.hover(), shorthand event methods (.click(),.change(), etc.),.size() - Removed
jQuery.fn.push,.sort,.spliceusage - Behavior changes:
jQuery.ajaxand$.get/$.postdefaults,.data()and.attr()edge cases,.addClass()/.removeClass()with arrays
Severity: start as warning, so it does not block submissions while the timeline is still tentative. Promote to error once jQuery 4 lands in core.
Also consider:
- A check for
wp_enqueue_script()calls that bundle their own jQuery or deregister core's jQuery (related to #702). - A readme / docs section pointing developers to
SCRIPT_DEBUGand the jQuery Migrate console warnings in 7.2.
Acceptance criteria
- New check registered, with a category such as
plugin_repoorperformance, and documented. - Each flagged API reports file, line, and a link to the replacement.
- Unit tests with passing and failing fixtures.
- Minified / vendored files are skipped, or flagged separately.
- Docs updated.
Related
- #1356: React 19 incompatibilities check (same "warn about upcoming incompatibilities" approach)
- #702: check for libraries already in WP core, including jQuery (bundling, not deprecated APIs)
References
- Lenguaje dominante
- PHP
- Estrellas
- 365
- Forks
- 135
- Merge medio
- 1 d 8 h
- PR fusionados (30 d)
- 20
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de WordPress/plugin-check
-
False positive trademarked_term warning for "wc" inside the word "Flowchart"Posiblemente ocupada @anandrajaram21 la tomó hace 3 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
WordPress/plugin-check#1556 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Add opt-in .distignore exclusions for local and CI scansPosiblemente ocupada @jakaria-istauk la tomó hace 1 día. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 42/100
WordPress/plugin-check#1559 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 58/100
WordPress/plugin-check#1557 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
WordPress/plugin-check#1555 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
PHPErrorReportingSniff flags debug constants used as values in const declarationsPosiblemente ocupada @elphizu la tomó hace 7 días. Abierto
Dificultad 3/5 Medio día Aptitud para principiantes 35/100
WordPress/plugin-check#1553 ·
Los mantenedores suelen responder en 1 día
Todos los issues de WordPress/plugin-check
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
ExpressionEngine/ExpressionEngine#5493 ·
Los mantenedores suelen responder en 5 días
-
"Attempt to read property 'username' on null" error after a user is deletedPosiblemente ocupada @dicksonlaw583 la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
omeka/plugin-SimplePages#49 ·
-
Bug Status: Needs Triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
quantum-php/project#222 ·
-
support
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día