Problem/Motivation
GitLab CI is reporting the following on the eslint task:
/builds/issue/project_browser-3441425/web/modules/custom/project_browser-3441425/js/project_browser.admin.js
39:14 error Prefer matches to $.is jquery/no-is
✖ 1 problem (1 error, 0 warnings)This would seem to be caused by #3227079: Support generating Code Quality JSON reports (for GitLab CI integration), which was intended to make validation in contrib more consistent with core.
Steps to reproduce
See pipeline output...
https://git.drupalcode.org/issue/project_browser-3441425/-/jobs/1377824
Proposed resolution
Ideally, the .is call should be replaced by .matches. However, that would require refactoring to use non-JQuery objects.
I think the simplest approach is to add a // eslint-disable-next-line comment to suppress the error.
I would like to refactor the JavaScript to remove JQuery completely, but I feel that should be left for a follow-on task.
Issue fork project_browser-3443929
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
lostcarpark commentedAfter fix ESLINT is passing.
Unfortunately there's another PHPCS issue, and I think this one is on us. Opened #3443930: PHPCS errors from 3310884 to look at that.
Comment #4
fjgarlin commentedAgree on limiting the scope of this issue. Thank for creating the follow ups.
This one looks good and the eslint job is passing now. RTBC.
Comment #7
chrisfromredfinThanks for getting us past this.