Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Word-wrap on sentence (punctuation) and width. #422

Closed
3 tasks
mdeweerd opened this issue Jan 28, 2024 · 1 comment
Closed
3 tasks

Word-wrap on sentence (punctuation) and width. #422

mdeweerd opened this issue Jan 28, 2024 · 1 comment
Labels
duplicate This issue or pull request already exists enhancement New feature or request

Comments

@mdeweerd
Copy link

mdeweerd commented Jan 28, 2024

Context

Start each sentence on a new line. Make lines short. as indicated in the documentation.

Currently we can make lines short with a target wrap width. However that breaks line wrapping at punctuations unless we add a double space or backslash.

Proposal

It's be nice if - while word-wrapping for line-length - mdformat could:

  • respect line wrapping already in place at a punctuation ('.', ';');
  • line-wrap at punctuations ('.', ';').

The options could take an optional parameter with the list of punctuations to apply them to.

Tasks and updates

  • Agree on options;
  • Implement the respect of existing line-wrapping on punctuation.
  • Implement adding line-wrapping on punctuation.
@mdeweerd mdeweerd added the enhancement New feature or request label Jan 28, 2024
@hukkin
Copy link
Owner

hukkin commented Jan 30, 2024

Closing as dupe of #4

@hukkin hukkin closed this as completed Jan 30, 2024
@hukkin hukkin added the duplicate This issue or pull request already exists label Jan 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants