I have successfully installed Commonmark.js through the NPM and successfully can convert md
files to HTML, this way:
commonmark test.md > test.html
Okay.
And after that, I tried to create this HTML file:
<script src="commonmark.js"></script>
<script type="text/javascript" src="commonmark.js"></script>
# header
text
text
(Also I previously downloaded javascript file itself and placed it together with HTML).
But when I open this file in web browser, I see just not formatted HTML:
# header text text
Instead of desired result:
What I’m doing wrong?
(There are no errors shown in Chrome Developer Tools).
I want it just for myselft. In other words, as replacement of Word. Open it with Sublime Text, write something, then open in Chrome and see the result. Something like Strapdown. Maybe I’m on a wrong way?