A change to our Prettier/ESLint setup has just landed <https://bugzilla.mozilla.org/show_bug.cgi?id=1809497> on mozilla-central:

 * Formatting issues are no longer directly raised by ESLint.
     o Formatting issues will not be raised by your editor with the
       default ESLint / Prettier plug-ins.
     o Enable save-on-format with Prettier in your favourite editor
       (more info below).
 * ./mach lint -l eslint and ./mach eslint will still work the same (as
   well as the --fix options).
     o They now run ESLint followed by prettier.
 * Phabricator & CI will still operate the same, but only state that
   the file needs formatting by Prettier, rather than the specific
   formatting errors.

*Editor Configuration*

It is highly recommended to enable automatic formatting when saving files. Most editors have options or plug-ins where you can enable Prettier <https://prettier.io/docs/en/editors.html> & ESLint <https://eslint.org/docs/latest/use/integrations> integrations.

For VS Code, we have updated ./mach ide vscode to automatically set the format on save options for Prettier. This assumes the recommended Prettier extension is installed.

./mach ide vscode will also now work for artifact builds.

There is more documentation about the VS Code setup in the contributing guide on Firefox source docs <https://firefox-source-docs.mozilla.org/contributing/editors/vscode.html> (it may take a few hours for the latest update to generate).

*Questions?*

Any questions, please visit #lint:mozilla.org on Matrix.

Mark

--
You received this message because you are subscribed to the Google Groups 
"[email protected]" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/a/mozilla.org/d/msgid/dev-platform/00284a9e-266d-d5ac-574a-7d010bf5452f%40mozilla.com.

Reply via email to