Skip to content

[Platform RFC] Run prettier --write on merge #17011

@GregBrimble

Description

@GregBrimble

A couple of assumptions:

  1. When making an edit, starting from a consistently formatted page makes creating that edit easier.
  2. Not everyone is making these changes in an IDE with Prettier installed (e.g. GitHub online directly)
  3. We don't want to block edits which don't conform to formatting rules. We do want to allow them to be made without any additional friction.
  4. We don't love reviewing PRs which come from contributors which have an auto-formatter installed on their IDE, so inadvertently pull in unrelated formatting changes with their PRs.
  5. Consistent formatting is useful to both contributors, and to our readers (esp. for code snippets).

I propose making a (non-trivial) effort to run prettier --write across the codebase, and then, in order to maintain that consistency going forward, run prettier --write again on every merge atop the contributor's content commits. Couple of ways we could technically do this, and I don't really mind about the specifics. Just wanted to start the conversation here about actually trying to uphold some consistency here.

Metadata

Metadata

Assignees

Labels

DevRelTasks that need support from developer relations.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions