snarkdown icon indicating copy to clipboard operation
snarkdown copied to clipboard

Add checks to ensure in-word formatting chars aren't replaced

Open jacobmischka opened this issue 4 years ago • 1 comments

Basic text formatting sequences (_, *, __, **) are now required to not be entirely within a word; that is, they must have a non-word character on either side to be replaced.

This prevents words that include those characters (snake_case words, or some proper nouns that may include an Embedded*Asterisk__Or**Two for some reason) from being captured.

Fixes #21

jacobmischka avatar Jul 26 '21 18:07 jacobmischka

Yes it's expected in most markdown formatters that one single underscore inside a word should not be interpreted as the start of an italic sentence with no end.

Could this PR be taken into consideration?

yanndinendal avatar Feb 06 '23 15:02 yanndinendal