This is probably not a very wise question, but does anyone have any idea how websites like https://rossprogram.org/ are made in TeX? I'm looking to make a personal website in LaTeX, but I don't know if it is even possible. Thanks!
4 Answers
Ross's website does not use TeX to create a website (I doubt you could use a .tex file to display a website anyways - though I may be incorrect in this regard). If you look at the footer of the site, you can see it says that it was created using Jekyll with Minimal Mistakes (which I presume to be some sort of add-on or theme for Jekyll).
If you meant how you can get your website to look like a LaTeX document, you could simply just spend some time writing a .css file that accomplishes this. Alternatively, you may want to check out this project: LaTex.css which styles your HTML as a LaTeX-esque document. It seems quite easy to set up as well.
- 171
- 3
-
Its a theme: https://mademistakes.com/work/minimal-mistakes-jekyll-theme/ – Ander Biguri Aug 08 '22 at 12:53
That site isn’t actually created with LaTeX. It appears to be created using Jekyll. Setting up a website to use Computer Modern (or, more likely a Unicode-based variant thereof), however, is off topic for tex.stackexchange.
There are tools like LaTeX2HTML that will convert LaTeX into HTML pages with varying degrees of fidelity and usability, not to mention tools like MathJax that simplify the use of LaTeX-like mathematics in HTML documents. A bit of googling can turn up some useful further information.
- 14,078
This answer might be off-topic compared to typical TeX.SE answers. I think the website doesn't really use TeX/LaTeX for generating the text. I think it displays ordinary text as LaTeX font (I am not taking about mathematical formulas as they are usually generated by MathJax or KaTeX). Computer Modern, the typical LaTeX font, is used in the website via CSS. I tweaked dreampulse's solution and attached this minimal html code. Create a file and ensure it is of type .html, paste the code, save it and then open it using your browser. The result should be:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>LaTeX Website</title>
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/gh/dreampulse/computer-modern-web-font@master/fonts.css">
<style>
* {font-family: "Computer Modern Serif", sans-serif; }
/* Comment here: fonts to use are
"Computer Modern Serif",
"Computer Modern Bright",
"Computer Modern Concrete",
"Computer Modern Sans",
"Computer Modern Serif",
"Computer Modern Typewriter"
*/
</style>
</head>
<body>
<p>Normal text <strong>bold text</strong> <i>italicized text</i></p>
</body>
</html>
To briefly explain, the line * {font-family: "Computer Modern Serif", sans-serif; } means change the font of all html tags to Computer Modern Serif.
Disclaimer: please ensure that the license is appropriate for your use.
- 4,035
- 2
- 11
- 26
I am on my phone (= I keep it short) and just want to add my two cents :).
- Maybe pandoc could be used for that.
- Maybe TEX4ht is an option.
- 22,451
-
3Well there's a full list pdftex - Convert LaTeX to HTML - TeX - LaTeX Stack Exchange – user202729 Aug 07 '22 at 04:38
-

You could write a site in LaTeX and compile it to HTML with TeX4ht/htlatex if you wanted, but it's unclear why you would; is there something more specific you're after?
– frabjous Aug 07 '22 at 02:45