jhuix / vscode-markdown-preview-showdown

A excellent markdown preview extension for Visual Studio Code.
https://marketplace.visualstudio.com/items?itemName=jhuix.markdown-preview-showdown
Other
7 stars 1 forks source link

Switching between markdown flavors #7

Closed sebi5361 closed 3 years ago

sebi5361 commented 3 years ago
vscode-markdown-preview-showdown doesn't render line breaks similarly to the embedded markdown viewer. See below: image above picture left column above picture center column above picture right column
markdown plain input default markdown interpreter vscode-markdown-preview-showdown interpreter

I think we talk of differ flavors (maybe it is not the appropriate term) for those parser language interpretation differences!?

I tried to play with the extension settings adding adding, for example, "markdown-preview-showdown.flavor": "vanilla" in the settings.json file, as mentioned in the documentation, but unfortunately it didn't change anything.

Could you explain how to change the markdown flavor (if I am using the appropriate term)?

jhuix commented 3 years ago

Default flavor is "github", it can be rendered correctly with the line breaks that be inputted by enter key. How do you enter text?

sebi5361 commented 3 years ago

I am entering text pressing the enter key...

sebi5361 commented 3 years ago

Yes "github" flavor works as expected with your viewer. I think the default markdown viewer works with the "original" flavor that displays text one after another if not separated by space + space + line break. How to switch your viewer to this flavor?

jhuix commented 3 years ago

Yes "github" flavor works as expected with your viewer. I think the default markdown viewer works with the "original" flavor that displays text one after another if not separated by space + space + line break. How to switch your viewer to this flavor?

OK. I will open showdown's native flavors include ["github", "ghost", "vanilla", "original"] in the next version

jhuix commented 3 years ago

Yes "github" flavor works as expected with your viewer. I think the default markdown viewer works with the "original" flavor that displays text one after another if not separated by space + space + line break. How to switch your viewer to this flavor?

OK. I will open showdown's native flavors include ["github", "ghost", "vanilla", "original"] in the next version

OR, try to set "markdown-preview-showdown.flavor": "original" in settings.json file for version 1.3.3.

sebi5361 commented 3 years ago

Adding "markdown-preview-showdown.flavor": "original" to %APPDATA%\Code\User\settings.json definitely triggered a modification to the rendering, as I had to close and reopen the display panel to see the rendered markdown correctly again. However still it looks like the "github" flavor...

jhuix commented 3 years ago

Adding "markdown-preview-showdown.flavor": "original" to %APPDATA%\Code\User\settings.json definitely triggered a modification to the rendering, as I had to close and reopen the display panel to see the rendered markdown correctly again. However still it looks like the "github" flavor...

Try the new version 1.3.4 again. The new version adds the flavor and delimiters setting.

sebi5361 commented 3 years ago

The flavor settings works perfectly. Neat! Thank you