Would there be any interest? header tags are used to make table of contents, anchor tags create Index entries, all the formatting tags (tables, un-numbered and numbered lists etc) do basic print formatting. All the bold/underline/italic also render to paper. Sort of like a poor man’s TeX.

Has anyone done this?

  • enfluensa@ttrpg.network
    link
    fedilink
    arrow-up
    2
    ·
    6 hours ago

    I use this one, and it’s pretty nice: https://weasyprint.org/. They implement their own rendering engine so its support of new features and edge cases isn’t the best, but every problem I’ve run into with it has been solvable with a little work. I really like it for laying out printed forms!

    • Max-P@lemmy.max-p.me
      link
      fedilink
      arrow-up
      7
      ·
      edit-2
      9 hours ago

      I used to write my papers in HTML and a custom print CSS file I made so it fits the school’s formatting requirements. It worked surprisingly well. Just write HTML, and then just print it, as basic as it gets. That was easier than bending LaTeX to the school’s template which was in MS Office format.

      Converting HTML to LaTeX sounds like a completely unnecessary nightmare!

    • geekwithsoul@lemm.ee
      link
      fedilink
      English
      arrow-up
      2
      ·
      9 hours ago

      Always frustrates me how underutilized @media print is. Always liked crafting some good CSS for it on sites, especially ones that I worked on that were document heavy.

  • Dessalines@lemmy.ml
    link
    fedilink
    arrow-up
    4
    ·
    8 hours ago

    There’s a lot of libraries that convert html to markdown (and in the process get rid of all the javascript spyware).

    The android app markdownr can do this on the fly, and I had an idea to create a markdown web browser using that as a base, but no time to work on it.

  • folekaule@lemmy.world
    link
    fedilink
    arrow-up
    3
    ·
    9 hours ago

    Yes this is a thing and it’s been around for quite some time. If you’re trying to approximate TeX, you may also be interested in MathML.

    I need to go lay down; I’m having flashbacks to the good old days of “XML everywhere for everything all the time”.

  • IrritableOcelot@beehaw.org
    link
    fedilink
    arrow-up
    4
    ·
    10 hours ago

    I mean you can do HTML -> TeX -> PDF with Pandoc, or to any other format pretty much. I would say writing markdown and passing it to TeX or directly to PDF is the most practical.