1. 10
  1. 2

    Cool hack! But the UX for the Luddites people who disable JS seems pretty bad — they get a page that’s blank but for a little bitty textarea. Why not use a PRE element instead? Then they see a full page, and it’s even in a Luddite-friendly monospaced font.

    1. 5

      To be honest, I did not put much work into what the output should look like when JavaScript is disabled. Due to the nature of what it does (that is, rendering itself at page load time), JavaScript is pretty much required to make it work. I chose the <textarea> element to put the input Markdown + LaTeX in because it is the most robust way of reading the input I found, that is, the TeXMe tokenizer reads exactly what was entered by the user. Using any other element such as <body> or <pre> leads to some loss of robustness in reading and parsing the input. More details about this can be found at README: Content in Body. Especially, see the Caveats section that talks about the parsing issues that arise when the input is not specified in the <textarea> element.

      Thank you for the feedback. The user experience for someone with JavaScript disabled is definitely something worth considering. I will keep that in mind while making further updates to this project.

      1. 2

        Putting it in a <noscript> element, might help the reader. Not sure if you can make your code look at another element that easily though…

    2. 2

      I really like it! The pdf-based look (I assume) is remarkably similar to the styling I use on my website (example of a post). Is this a coincidence?

      Anyway, if I had preferred dynamically rendered math I might have switched to TexMe.

      1. 3

        Thank you for the feedback. The default stylesheet is indeed inspired by how Chrome and Firefox rendered PDFs when I began writing this tool. I guess that explains the similarity of the styling with that of your posts. :-) The styling of your posts look cool. You have a wonderful blog with great content. Thanks for sharing it here.

      2. 1

        Update: The post URL containing the demo page has now moved to https://susam.github.io/texme/examples/demo.html.