Tapatalk

Saving Markdown file as HTML?

Saving Markdown file as HTML?

31
NewbieNewbie
31

PostOct 01, 2020#1

The recent version of UltraEdit (27.10.0.76) supports Markdown highlight syntax and it also shows Live Preview of Markdown documents.
However, I have not found a way how to generate HTML file out of the Markdown. I suppose it should be easy, as the Preview is probably based on the HTML anyway.
I would appreciate any hints on how to do that. Thanks!

6,823625
Grand MasterGrand Master
6,823625

PostOct 01, 2020#2

It is not possible to convert a Markdown file into an HTML file using CSS specified in a CSS file.

It is right that UltraEdit has built-in a Markdown interpreter which converts a markdown file to HTML for live preview. But UltraEdit v27.10 has no command to save a Markdown file as HTML file. You would need another tool for markdown to HTML or PDF conversion. There are lots of free tools available for Windows for that purpose.

31
NewbieNewbie
31

PostOct 01, 2020#3

Many thanks for clarification.

I tested several markdown to html/pdf converters, but the issue is that the preview in UltraEdit looks different (better) than the converted HTML code from most of them. It would be nice to get html exactly corresponding to the preview.

But I suppose it is what it is and I will use an alternative solution.

6,823625
Grand MasterGrand Master
6,823625

PostOct 01, 2020#4

Hint: The look of the HTML file produced from a Markdown file depends on the CSS specifications which are added to top of the created HTML file.

31
NewbieNewbie
31

PostOct 06, 2020#5

Thanks for the hint :-) Here is what worked for me:
1. I created/modified a CSS style that produces the format I need.
2. I added the CSS style into UltraEdit (Live preview -> Add/remove style) and selected it for my document.
3. I used pandoc to convert Markdown to HTML, using the same CSS style.
So now the generated HTML with CSS looks exactly same as the Preview in UltraEdit.