I've tackled this issue by replacing the markdown-it-highlight package with the markdown_it_highlightjs package that serves the same purpose but behaves correctly for the issues reported.
It also seems to be the prefered package for this functionality in npm if we take into account the number of weekly downloads.
To avoid any change in styling I'm applying the same theme used internally by the old package: atom-one-light.
Example before fix:
Example after fix:
I've also removed the yarn.lock file since you seem to be using npm as the package manager.
I've tackled this issue by replacing the markdown-it-highlight package with the markdown_it_highlightjs package that serves the same purpose but behaves correctly for the issues reported.
It also seems to be the prefered package for this functionality in npm if we take into account the number of weekly downloads.
To avoid any change in styling I'm applying the same theme used internally by the old package: atom-one-light.
Example before fix:
Example after fix:
I've also removed the
yarn.lock
file since you seem to be usingnpm
as the package manager.Closes standardnotes/bounties#17