mdformat
mdformat copied to clipboard
fix: Thematic breaks should respect wrap length
Currently, a thematic break (hr) will always be 70 characters. This PR makes the thematic break respect the given wrap length.
- If the user gives no wrap length, 70 characters will be used as per today.
- If the user gives a very small wrap length, 3 characters will be used, as per the spec.
Hey, thanks for the PR!
The --wrap feature is really only intended and documented to wrap paragraph text. This would be a new feature that can be considered in a separate issue or together with larger changes here https://github.com/hukkin/mdformat/issues/331.
One other option to consider is contributing to this existing plugin: https://github.com/csala/mdformat-simple-breaks/issues/1