5 ms·
You may not even need HTML. HTML is subject to different renderings on different browsers, confusing features that may not be supported on different browses, an
by tolmasky 4y ago
You may not even need HTML. HTML is subject to different renderings on different browsers, confusing features that may not be supported on different browses, and may tempt you to use JavaScript (which can throw "errors" if written incorrectly).
If you stick to text files, you'll never have to go to caniuse.com ever. Need styles? Just make a PDF and throw that online. During the "XML HTML" phase the web went through, I never had to worry about validating my PDFs through an XML validator. Then when everyone decided using "<b>" and "<font>" tags was bad and insisting we switch to using "font-weight" CSS in a completely unrelated part of the file, guess what I had to do? Nothing! My PDF keeps rendering exactly the same way through every silly "trend" and "update" on the web, and never misses a beat on Lighthouse in Chrome.
Now if I could just convince all the browsers to implement .docx renderers out of the box, I'd really be set.
- kevincox 4y agoGood luck having your site be easy to read on both mobile and desktop with either of these approaches. text/plain may work if you use soft wrapping, but even then most desktop will need to resize their browser window to make it narrow enough to read comfortably.
- tolmasky 4y agoI love that you went with easiness to read and not "wait, how does anyone navigate on your site without links in plain text files?"
- kevincox 4y agoIf I can't read your site non-clickable links is not going to be an issue as I will never get that far!
- nonethewiser 4y agoBut the claim was it wouldn’t be easy on mobile. So it’s fine desktop and not necessarily unreadable on mobile.
- mminer237 4y agoPDFs are pretty horrible to use on a phone and add much more overhead than CSS and even JS would.
- sodimel 4y ago> Need styles? Just make a PDF and throw that online. Just use some old chars (maybe them? https://en.wikipedia.org/wiki/Symbols_for_Legacy_Computing https://en.wikipedia.org/wiki/Symbols_for_Legacy_Computing) and some spaces and boom, a nice style in a simple txt file!
- smm11 4y agoGet Display Postcript working and I may be with you.
- OkayPhysicist 4y ago> HTML is subject to different renderings on different browsers This only matters if you actually care about exactly how your website renders on any given browser. Most websites don't have any need to care. PDFs are the worst for this: They care, A LOT. Which means locking you in to some hideous rectangle that's a different aspect ratio than any monitors I own, locking down the fonts and colors so that I can't just rely on system defaults, etc. If all you need is to convey text, and maybe take some input, HTML is a fantastic solution.
- jppope 4y agofor all the responses going into practical implications... I think @tolmasky is joking