Skip to content

Use prettier for markdown formatting#53

Open
konstin wants to merge 1 commit intomainfrom
konsti/use-prettier-for-markdown-formatting
Open

Use prettier for markdown formatting#53
konstin wants to merge 1 commit intomainfrom
konsti/use-prettier-for-markdown-formatting

Conversation

@konstin
Copy link
Contributor

@konstin konstin commented Jun 20, 2025

Manually wrapping the lines in markdown files is cumbersome, so I've added prettier which prose-wraps and formats those files for us. It also gives us consistency between the files that are currently not wrapped at a line length and those that are.

The only text change is the new "Contributing" section that explains how to run prettier:

npx prettier --prose-wrap always --write "**/*.md"

@mgorny
Copy link
Contributor

mgorny commented Jun 20, 2025

The only thing I really dislike about this is that it's forcing articles to the end of the line, etc. Technically we could solve this by using non-breaking spaces, but perhaps it's not that important for these docs.

@konstin
Copy link
Contributor Author

konstin commented Jun 24, 2025

As I understand wrapping only based on word length is the general approach in books, magazines and even the tex rendering algorithm, so I'd align with that.

@DEKHTIARJonathan
Copy link
Member

@konstin can you solve the CI lint check and address the conflict ?

@konstin konstin force-pushed the konsti/use-prettier-for-markdown-formatting branch from bd4d468 to 12bc2bf Compare June 24, 2025 20:40
Manually wrapping the lines in markdown files is cumbersome, so I've added prettier which prose-wraps and formats those files for us. It also gives us consistency between the files that are currently not wrapped at a line length and those that are.
@konstin konstin force-pushed the konsti/use-prettier-for-markdown-formatting branch from 12bc2bf to 31cbd05 Compare June 24, 2025 20:41
@konstin
Copy link
Contributor Author

konstin commented Jun 24, 2025

Done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants