Live data from Hacker News

Show HN: Markdown page – Create a web page with just markdown

github.com

71–80 of 86 posts

Re: Show HN: Markdown page – Create a web page with just markdown

#71

I wonder what effect having a page solely in markdown has on SEO? Without markup for headers, links, etc, how will search engines prioritize content? Will they use the raw content or the parsed HTML?

I'd imagine anyone particularly concerned with SEO would be likely to prefer a more fully-featured method of content management anyway.

One of the problems of the modern web.

Sure we can add JavaScript and make the web work the way we want, like this example, but many more... but what about SEO?

For example, I had a page for my app, it was very minimalistic and pretty, I targeted the 400 msec cold loading time, instead of a screenshot, I had a very well encoded h.265 screen recording (it's okay, people who can run the app, can certainly see the video), that video didn't cost more than a well optimized JPEG.

But I had to drop the video, and only load it after the JPEG loaded because of SEO reasons. Google isn't smart enough to recognize the video unless it's a YouTube video.

Re: Show HN: Markdown page – Create a web page with just markdown

#72
post #37
post #32

Earlier quoted context omitted.

So does HTML/CSS+JS. A project aiming at simplicity probably isn't one to criticize for lack of features.

the mechanism for using both the projects is the same -- include a JS file. If the effort to use both is the same, why would I not use the one that has more features?

Maybe he doesn't need the features, or maybe it is slower

Re: Show HN: Markdown page – Create a web page with just markdown

#73
post #29

The flicker when loading the page sucks. I guess displaying Markdown in case of failure is not the worst thing, but it would be nice if there was a possible way to allow getting rid of the flicker at the cost of not having a graceful fallback. One way you could accomplish this is by supporting script tags for this, like wrapping the page in: ... ...as an optional way to use the library. Browsers won't (shouldn't?) tr…

fixed the flicker, was a Cloudflare rocket script issue

Re: Show HN: Markdown page – Create a web page with just markdown

#74

So how does this work exactly? It looks like you wrote a script.js file, which calls showdown.js library (converting markdown to html). A uglified version called `md-page` is made pulling both resources Basically, the script does following 1) wait for page to load 2) add css-styles via javascript 3) shove all the markdown in a variable "markdown", passing it as one giant string 4) Add settings for showdown.js 5) Rewr…

yep. you're 100% on the money. no wizardry here. Couple of extra features like ability to hash link, and external url open in new window. but that it

Re: Show HN: Markdown page – Create a web page with just markdown

#75
post #36
post #29

The flicker when loading the page sucks. I guess displaying Markdown in case of failure is not the worst thing, but it would be nice if there was a possible way to allow getting rid of the flicker at the cost of not having a graceful fallback. One way you could accomplish this is by supporting script tags for this, like wrapping the page in: ... ...as an optional way to use the library. Browsers won't (shouldn't?) tr…

Yesss, finally a use-case for the ` `-hack! This is actually even better than the approach of OP since we're guaranteed to get a plain text representation of the text (instead of the browser parsing it as HTML). example.html: # Header Welcome to my simplest site - A - awesome - list mdpage.js: document.write(" "); document.addEventListener("DOMContentLoaded", function() { var script = document.createElement('script')…

Thanks @judofyr + @matt-tingen. I just updated it to use the 'noscript' opening tag. Good idea, and solved my normal html not working problem! Thanks a bunch!

Re: Show HN: Markdown page – Create a web page with just markdown

#76
post #58
post #57

Earlier quoted context omitted.

Why would you want to constantly recompile documents every time you make an edit to them? Why would you want to juggle two files for every document you produce?

For what it's worth, this is the problem GitLab Pages solves. A simple "git push" to a properly to figured repo will rebuild and redeploy your static site, the actual html output doesnt go into the repo.

This is for people who don't want to setup and manage a deployment pipeline hooked up to a git source code repo.

Re: Show HN: Markdown page – Create a web page with just markdown

#77
Thanks everyone for taking the time to look, and give some feedback. Most definitely better options out there, but I was really aiming for simple, and low tech knowledge to get a md page on the internet.

I added a wiki page https://github.com/oscarmorrison/md-page/wiki explaining a couple of use cases, and some more details. Feel free to leave more feedback / open issues. Thanks Oscar!

Re: Show HN: Markdown page – Create a web page with just markdown

#78

Honestly, I prefer writing directly plain html5 with implicit tags. I cannot see any advantage of markdown over html for this particular usage.

Markdown doesn't require tag closure, and eliminates the tag entirely. This makes for a cleaner and faster composing experience. I did little but wruite in HTML from the late 1990s to mid 2010s. Markdown is my preferred route now. Also conversant in LaTeX, formerly; nroff, DocBook, WP4.2, Wordstar (both with 'reveal codes' capabilities), and probably more. Pandoc is a game-changer.

> Markdown doesn't require tag closure, and eliminates the

tag entirely. This makes for a cleaner and faster composing experience.

The HTML5 specification also allows omitting most closing tags (except for the obvious ones, that you also need to close in markdown).

You are right about the

tag, still. It is the main source of annoyance when writing long documents in html by hand.

Re: Show HN: Markdown page – Create a web page with just markdown

#79
post #63

This is kind of neat but why not just use pandoc? pandoc -s input.md -t html -o output.html https://pandoc.org/

Pandoc is kind of neat but why not just use markdown? markdown input.md > output.html

It is a personal preference but I would rather know one tool they is more versatile (especially for such a task)

Re: Show HN: Markdown page – Create a web page with just markdown

#80

Earlier quoted context omitted.

Markdown doesn't require tag closure, and eliminates the tag entirely. This makes for a cleaner and faster composing experience. I did little but wruite in HTML from the late 1990s to mid 2010s. Markdown is my preferred route now. Also conversant in LaTeX, formerly; nroff, DocBook, WP4.2, Wordstar (both with 'reveal codes' capabilities), and probably more. Pandoc is a game-changer.

> Markdown doesn't require tag closure, and eliminates the tag entirely. This makes for a cleaner and faster composing experience. The HTML5 specification also allows omitting most closing tags (except for the obvious ones, that you also need to close in markdown). You are right about the tag, still. It is the main source of annoyance when writing long documents in html by hand.

Well-formed HTML5 needs closure though, no? Hrm ... ok, looks like specs are far looser than I'd thought.

h[1-6], li, blockquote, pre, can all be specified via an opening-only syntax.

p, ul, ol, and dl can be omitted entirely.

Arguably anchors require closure, but the syntax is still briefer than HTML. Images likewise.

Header, footer, and aside don't exist (they can be supplied in a template). article, div, and span are also ignored.

Italic, bold, strikeout, code, subscript, and superscript require a lightweight closure, and are actually the main cause of grief in my Markup writing.

Tables are hugely more sane.

And footnotes automajickally exist. Swoon!

It's not that HTML is foreign or annoying to me. It's just .... more frictional.

And I have all kinds of nice words to say for HTML5. The base spec is quite good.

Post reply on HN