learnyouahaskell.github.io
learnyouahaskell.github.io copied to clipboard
Make preparations for switching to markdown-generated HTML
In pull request #35 for issue #8, I added a markdown version of the website, but the HTML files generated from the markdown couldn't be used directly, because they required some changes to the CSS and JavaScript files. (Also, the relative links to assets were broken, because the generated HTML was stored in a different directory from the original HTML.)
The current pull request resolves this by changing the original website HTML step by step in a series of commits, ending up with HTML that is identical to the markdown-generated files. These commits include the necessary changes to CSS styles, and in one case change to a few lines of the JavaScript used to highlight code blocks. There are also a few changes to the markdown itself and the shell script generating the HTML. I broke the PR down into a series of separate commits in order to show what changes are required.
The result is a working website that is almost identical to the one before the changes, with only subtle differences: the only ones I am aware of are curved quotation marks replacing straight quotation marks in the main text and the trimming of blank lines at the end of a couple of code blocks.
Of course, merging this pull request does not mean you have to switch to generating the website from the markdown source, but it removes almost all of the obstacles to adopting markdown, if you decide to. It shows what needs to change in order for the markdown source to be actually used for building the website. Please ask if you have any questions or want more details.
I fully support the idea to switch to markdown-generated HTML, but right now it is not that easy to me to fully understand the status of this PR. What needs to be done to finally merge this work? I am willing to help, but a bit overwhelmed.
Would love to see this in action, and am happy to be another pair of eyes.