Closed
Bug 1243764
Opened 8 years ago
Closed 8 years ago
Fix camelcase warnings in webconsole.js
Categories
(DevTools :: Console, defect)
DevTools
Console
Tracking
(firefox47 fixed)
RESOLVED
FIXED
Firefox 47
Tracking | Status | |
---|---|---|
firefox47 | --- | fixed |
People
(Reporter: ajkerrigan, Assigned: ajkerrigan)
References
Details
Attachments
(1 file, 3 obsolete files)
75.84 KB,
patch
|
linclark
:
review+
|
Details | Diff | Splinter Review |
+++ This bug was initially created as a clone of Bug #1243133 +++ After the brace-style formatting addressed in Bug 1243133, the next biggest chunk of ESLint violations comes from the camelcase rule (125 warnings). The violations seem to come exclusively from method names. At first glance it looked like the naming was not in line with the MDN JavaScript practices (https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#JavaScript_practices), but webconsole.js has a XUL overlay and the method names do follow the advice set forth here: https://developer.mozilla.org/en-US/docs/JavaScript_Tips#Function_and_variable_naming If the naming is good as is, perhaps the fix for this bug is as simple as a comment to disable ESLint camelcase checking: /* eslint camelcase: 0 */ I'm happy to take this on or kick ideas around, just wanted to get some thoughts down first and avoid plowing ahead with a counterproductive fix.
Assignee | ||
Updated•8 years ago
|
Blocks: 1232731
Flags: needinfo?(lclark)
Summary: Fix brace-style warnings in webconsole.js → Fix camelcase warnings in webconsole.js
Comment 1•8 years ago
|
||
Thanks for checking on this! Just noting here for posterity: We talked about this in #devtools. :gl and :tromey thought this was no longer necessary because it was put in place to help with debugging when stack traces weren't as nice. :ajkerrigan also found this documentation of the rule, which seems to be XUL related: https://developer.mozilla.org/en-US/docs/JavaScript_Tips#Function_and_variable_naming. We decided to give it a try removing the names.
Flags: needinfo?(lclark)
Assignee | ||
Comment 2•8 years ago
|
||
This change eliminates a class of ESLint errors (camelcase), while also bringing the method definitions in line with the MDN Coding Style guidelines.
Assignee | ||
Comment 3•8 years ago
|
||
This change eliminates a class of ESLint errors (camelcase), while also bringing the method definitions in line with MDN Coding Style guidelines.
Assignee | ||
Updated•8 years ago
|
Attachment #8713466 -
Attachment is obsolete: true
Assignee | ||
Comment 4•8 years ago
|
||
This change eliminates a class of ESLint errors (camelcase), while also bringing the method definitions in line with MDN Coding Style guidelines.
Assignee | ||
Updated•8 years ago
|
Attachment #8713471 -
Attachment is obsolete: true
Assignee | ||
Comment 5•8 years ago
|
||
Comment on attachment 8713473 [details] [diff] [review] Remove named function syntax from webconsole.js methods Please also assign this bug to me. I didn't notice it was still unassigned until I went to submit the patch. Thanks!
Attachment #8713473 -
Flags: review?(lclark)
Comment 6•8 years ago
|
||
Comment on attachment 8713473 [details] [diff] [review] Remove named function syntax from webconsole.js methods Review of attachment 8713473 [details] [diff] [review]: ----------------------------------------------------------------- This looks good to me! The only problem is that the patch doesn't apply anymore because it's changing the same lines as you did with yesterday's patch (which has been committed). Once that has been resolved and the patch applies, I'll be happy to r+ it.
Attachment #8713473 -
Flags: review?(lclark) → review-
Assignee | ||
Comment 7•8 years ago
|
||
This change eliminates a class of ESLint errors (camelcase), while also bringing the method definitions in line with MDN Coding Style guidelines.
Assignee | ||
Updated•8 years ago
|
Attachment #8713473 -
Attachment is obsolete: true
Assignee | ||
Comment 8•8 years ago
|
||
Comment on attachment 8713731 [details] [diff] [review] Remove named function syntax from webconsole.js methods Well that was silly, I made merge conflicts solo. The updated patch should work a little better :).
Attachment #8713731 -
Flags: review?(lclark)
Assignee | ||
Updated•8 years ago
|
Assignee: nobody → ajkerrigan
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Comment 9•8 years ago
|
||
Comment on attachment 8713731 [details] [diff] [review] Remove named function syntax from webconsole.js methods Review of attachment 8713731 [details] [diff] [review]: ----------------------------------------------------------------- Great, thank you! I pushed to the try server to test it: https://treeherder.mozilla.org/#/jobs?repo=try&revision=8be86e84ccf1&selectedJob=16110679. None of the oranges seem related, so it looks good to me.
Attachment #8713731 -
Flags: review?(lclark) → review+
Updated•8 years ago
|
Keywords: checkin-needed
Comment 10•8 years ago
|
||
https://hg.mozilla.org/integration/fx-team/rev/7000943f09de
Keywords: checkin-needed
Comment 11•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/7000943f09de
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox47:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 47
Updated•6 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•