Follow-up of #1664940: [Policy, patch] Decide on JSHint configuration and part of #1415788: Javascript winter clean-up
Run jshint on the files with the configuration from the parent issue or use jshint.com with the following options:
/*jshint forin:true, noarg:true, eqeqeq:true, undef:true, curly:true, browser:true, expr:true, latedef:true, newcap:true, trailing:true */
/*global drupal, jQuery */
Fix any warnings or errors the tool finds.
Check manually that the fixes did not break any functionality.
Create patch and upload for the testbot.
Files: modules/views/js/ajax.js
Comments
Comment #1
rballou commentedInitial JSHint pass:
Comment #2
rballou commentedCleaned up Drupal, the regexp character escaping issues, and the radix parameter. I still need to come back and assess/change the unused variables (normally part of the function arguments).
Comment #3
rballou commentedCleaned up the unused variables. I have added two patches: the "combined" patch is both sets of changes, the "unused" is just the second set of changes.
Comment #5
rballou commentedUpdated the patch to keep Drupal as Drupal
Comment #6
dawehner#5: core-js-jshint-views-ajax-drupal.patch queued for re-testing.
Comment #8
nod_Updated the jshint config, here are the errors that needs fixing now:
Comment #9
droplet commentedComment #10
nod_Works :)
Comment #11
catchCommitted/pushed to 8.x, thanks!