[Firefox addon] Enforce double quotes, using ESLint, to avoid linting errors in mozilla-central (issue 7957) #7991
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Given that this patch causes a lot of churn in the addon code, I wouldn't really mind if we ultimately decide against doing this and just add a rule exception in mozilla-central instead.[1]
Edit: Another option, besides taking this patch or adding an ESLint exception in mozilla-central, could perhaps be to run all of the addon specific files through the new preprocessor instead and have it convert the quotes for us.
However, using the preprocessor could potentially hurt readability of those files (depending on what esprima/escodegen parameters are used), and I'm not sure how important it is that these files are easily readable in mozilla-central.
Re: #7957 (comment).
[1] Note that I used the ESLint
--fix
option, hence writing this commit message actually took longer time than the creation of the patch :-)