Closed Bug 1195354 Opened 7 years ago Closed 5 years ago

Use ignorePattern in max-len rule to ignore data uris for devtools eslint

Categories

(DevTools :: Framework, defect)

defect
Not set
normal

Tracking

(firefox43 affected)

RESOLVED WORKSFORME
Tracking Status
firefox43 --- affected

People

(Reporter: bgrins, Unassigned)

References

Details

See discussion at https://bugzilla.mozilla.org/show_bug.cgi?id=1194314#c6.

At least in tests, there are cases where we have a Data URI stored in a file, and it's awkward to string concatenate that just to fit within the 80 char limit.  Apparently there is an option to the max-len rule where we could pass in some kind of pattern to make it skip these strings.
It looks like devtools' .eslintrc.js file is already doing this:

https://searchfox.org/mozilla-central/rev/efce4ceddfbe5fe4e2d74f1aed93894bada9b273/devtools/.eslintrc.js#115

at least for data:image (I'd assume more would be added if/when necessary).
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → WORKSFORME
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.