speechmarkdown / speechmarkdown-js

Speech Markdown grammar, parser, and formatters for use with JavaScript.
MIT License
76 stars 16 forks source link

Dashes in dates get treated as emphasis #73

Closed arjan closed 1 year ago

arjan commented 2 years ago

When there is a date, formatted with dashes, these dashes still get treated as emphasized text. So when using toText it means the dashes get stripped.

So 2020-10-10 becomes 20201010. this is quite unexpected.

Note this only is the issue for numbers, for normal words it is ok, Mother-in-law for instance stays untouched.

Would it be an option to treat numbers as word characters as well?

beevelop commented 1 year ago

Thank you for the updates @arjan 🙏