An introduction to XHTML
I had joined Repl.it only slightly over a year, and I've been involved in web development for even less time, but there was always one thing that threw me off about web dev: the choice of languages.
If I were to develop a native application, I could choose from Swift, Go, Rust, Java, Python, C#, Perl, Scala, Kotlin, Dart, Julia, Scheme, or any of the other languages in existence, each with their pros and cons. but then I'm told that on the web... you don't get to choose at all.
All web pages are written in HTML, CSS, and JS; that's it. Repl says the same; there is a dedicated "HTML, CSS, JS" Repl after all.
It is looked down upon to even go against any of the "big three" languages.
I could write at least an entire essay on how HTML, CSS, and JS are anything but the best languages for the web and why they are far from future-proof.
But what's interesting is that I am willing to bet that your very browser supports more than those three languages.
Surely you have viewed an image through your browser? If so, your browser likely supports a plethora of image binary encodings.
Maybe you've watched a video on YouTube? Add in a bunch of video and audio encodings.
Have you ever heard of Flash? Add another language.
Some older developers might have heard of Java applets. That's another language to add.
Does anyone here on the bleeding edge of tech know about WebAssembly? +1 to the language list.
Surely you have heard of XML? XML is very close to HTML, although it's younger than HTML. Browsers support it, so make that one more to the list.
XSL is used by XML, just one more to the list.
And guess what? The list goes on! So now, maybe you'd start to question why are web pages developed in HTML, CSS, and JS too.
Maybe they're just the best languages? To that, I say, "no, they're not."
If anything, I would suggest that you take a look at another language that your browser most likely supports: XHTML.
I believe that if everyone were to eventually use XHTML, the web would be better; this is merely an introduction to the language.
I present to you an informative, beautifully written web page in XHTML, supporting the use of XHTML, and explaining the very basics of the language:
Credits to @19wintersp for co-authoring the document, their contributions to the CSS, in particular, practically creating the entire navbar on their own, and many other miscellaneous contributions!
Getting XHTML on Repl.it:
Every upvote for the XHTML language request brings the language one step closer to being officially supported!
@RayhanADev I've tried the Wasm Repls here, and it's so immature. My beta Chrome browser has more features. They need to update it (like every other language on Repl (except maybe Python3))
YAY you finally posted this!!!
Yes! I'm the slowest person out there, but we got it done... eventually!
HEY!!! THIS IS A DISGRACE. HOW COULD FREAKING JS HTML OR UGH- CSS EVER, EVER, EVER "Look down upon" LANGUAGES LIKE C++ PYTHON OR EVEN- I KNOW THIS IS RIDICULOUS- C#???!?!?!?!?!?1/!?!?!!?!?!?!?!?!?!!?!?!?Also, I'm actually not mad but whatever UGH
@gjirtngisnt Omg... I am referring to web development, and not addressing native development at all in the post, same applies to the web page.
To say that HTML is bad and that the web should've been built on something else generally doesn't go well.
Most of my code is for native development, not web dev, I would never even compare them since native code is always better than anything running on the web.
great tutorial, and I agree with most things said in the post, a lot of devs are now using either stuff like react or nextjs and many more langs to create websites that are not just solely html, js and css. Tailwind also comes to mind in the sense of styling.
But feel free to fork the Repl if you want to!
(also, check Repl's highlighting on the site
, it's terrible)
this looks like you put in a lot of work, and yes, we should get XHTML for all the language explorers on Repl.it
XHTML is cool. Yes, I truly have known the power of this for a bit now. Although, I don't need to use XHTML right now, but it's always tucked in my holster in the case I need to use it. Guys, seriously. What this guys is saying is true: XHTML is very powerful!!!
@Baconman321 Indeed, it is. That is why I (and others) consider XHTML to be future-proof, whereas HTML depends on the standard to define the very syntax for the new elements, XHTML already has a format and syntax.
So, today, if you were to create an element in the standard, your XHTML page wouldn't break based on the tag's format if you open in an old browser, but it would with HTML.
In a way, XHTML can be considered a "lower-level" markup language, because it gives more direct or "raw" access to the structure that HTML does not provide. With that being said, I still believe that XHTML is easier to learn and use than HTML. In fact, it helped catch a few bugs that wouldn't have been caught otherwise in the making of the very web page!
Yet, without many users, and a small market share, no one will ever care about it. :(
@CoolGuy27 Actually, you might want to look at the Repl itself; I wrote the entire page in XHTML and styled using CSS. I'm just using some hacky HTTP redirect to make it work.
Repl.it does not have first-class support for the language yet, but I'm hoping that we could get enough people to upvote the three feedback links that I posted down here in the comments.
If we can get enough to vote, the language might end up on the list of languages along with everything else that Repl supports!
The links are also in the Repl's feedback.md.
Also, thank you, it's great to hear that someone liked it!
Just a styling suggestion:
When you view the website in full screen, the font is a little too big. Could you make this font just a little bit smaller?
All web pages are written in HTML, CSS, and JS
Well, unless you make your own custom web browser :)
Like, a full web browser from the bottom up with a GUI front end, and a web engine backend, with networking as well.
I might do that soon
Have you ever heard of Flash? Add another language.
Isn't Flash dying?
Nice! Though you do get more choice, since there's all the languages that transpile to JS (Elm, Roy, etc).