Comment by aktau
17 hours ago
I have the same question. It seems like a decent amount of posters here don't require (non-standard) interactivity. Plain HTML+CSS (perhaps via static site generators) would work.
It made me think about the Javascript present on my blog. The site works fine without JS (syntax high-lighting is pre-baked server-side).
There is some optional JS enhancement:
- MathJax is used for turning LaTeX expressions into nice graphics on the client-side. A search reveals this could be done on the server-side, but I'd need to deal with the node.js ecosystem.
- PJAX is enabled [1]. This is completely optional, but it noticeably made page navigation faster (feel instant), especially when navigating between pages already visited (forwards/backwards).
UPDATE: Reading https://triptychproject.org/, it seems like what PJAX does is item #3: "Partial page replacement"
[1]: The library is at https://www.aktau.be/js/pjax-standalone.js. It is invoked at the end of <body>:
pjax.connect({
"container": "content",
"complete": function() { MathJax.typesetPromise(); }, // Reload mathjax after a pjax load.
"autoAnalytics": false
});
No comments yet
Contribute on Hacker News ↗