Closed Bug 1242254 Opened 4 years ago Closed 4 years ago

Enable initial set of eslint rules for PSM

Categories

(Core :: Security: PSM, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla47
Tracking Status
firefox47 --- fixed

People

(Reporter: Cykesiopka, Assigned: Cykesiopka)

References

Details

Attachments

(1 file)

eslint is now run as part of checkins to m-i and other branches, and can be run locally as well.

As such, it would be a good idea to take advantage of this and lint PSM JS files to catch errors and style issues earlier.

To start, we should enable rules that already pass, or will pass with minor code modification.
These rules are copied from toolkit/.eslintrc (with non-passing rules excluded and previously commented out and passing rules included).

Review commit: https://reviewboard.mozilla.org/r/32199/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/32199/
Attachment #8711447 - Flags: review?(dkeeler)
Comment on attachment 8711447 [details]
MozReview Request: Bug 1242254 - Enable initial set of eslint rules for PSM.

https://reviewboard.mozilla.org/r/32199/#review29193

Great - thanks.

::: security/manager/pki/resources/content/createCertInfo.js:26
(Diff revision 1)
>    

Is there a no-trailing-whitespace option? That would be nice...

::: security/manager/pki/resources/content/password.js:46
(Diff revision 1)
>       var i=0;

Is there an option to enforce spaces around '='?
Attachment #8711447 - Flags: review?(dkeeler) → review+
Blocks: 1243179
https://reviewboard.mozilla.org/r/32199/#review29193

Thanks for the review!

> Is there a no-trailing-whitespace option? That would be nice...

Yup - see Bug 1243180.

> Is there an option to enforce spaces around '='?

Yes as well - see Bug 1243182.
https://hg.mozilla.org/mozilla-central/rev/f7a9136388ea
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
You need to log in before you can comment on or make changes to this bug.