Live data from Hacker News

Write HTML Right

lofi.limo

61–70 of 212 posts

Re: Write HTML Right

#61

I like the aesthetic though I'm not sure how sustainable it is beyond basic content documents. On a side note though, I clicked around and big props to Aaron on the lofi.limo project, this is very cool.

Thank you for the kind words! I've been working on adapting this style for web apps, but I haven't got it figured out well enough to write an article about. Yet...

I wouldn't mind if we had a bunch more basic content documents on the web.

Re: Write HTML Right

#62
post #53

Earlier quoted context omitted.

It’s funny you bring this up because while I have joined the Tables For Layout Are Considered Harmful club, I never really have heard a completely convincing argument on why tables have this bad rap. I think it’s mostly because, semantically, tables don’t make sense for layout, but back in the days before frameworks such as Foundation and Bootstrap (and more recently native CSS3 mechanisms), tables with invisible bor…

There was never a well-substantiated argument for the alleged harm of layout tables. Demonizing them mostly just stemmed from the cult of wanting to completely confine layout to CSS vs. expressing semantics with HTML. In the end that “CSS zen” was never really achieved, because the dependencies between HTML structure and styling are just too many and too strong.

> There was never a well-substantiated argument for the alleged harm of layout tables.

What was the best argument that you can recall? What were some of the bad ones? What does "harm" mean in this context?

> because the dependencies between HTML structure and styling are just too many and too strong.

Which dependencies? What would a structure/styling language combination look like that that lacked or had weak dependencies?

Re: Write HTML Right

#63
post #23
post #19

Earlier quoted context omitted.

I feel like this style just makes it harder to read and understand the HTML. But hey, if it works for you, great.

This is the output of an app/templating system, i.e. not a single HTML page. Have you ever read the HTML of any dynamically generated page? It's unreadable.

> Have you ever read the HTML of any dynamically generated page? It's unreadable.

Not with that attidude... if you write consistently and with intention, it turns out just fine.

Check out the source for https://try.nodebb.org, for example. Dynamically generated, (mostly) syntactically correct, (mostly) human readable.

Re: Write HTML Right

#64
> A few years ago, I found out I'd been tying my shoes wrong for my entire life. I thought laces came undone easily and didn't usually look very good. At least that's how mine were, and I never paid much attention to anyone else's. It took a couple of weeks to re-train my hands but now I have bows in my laces that look good and rarely come undone.

I’m equally interested in this as the HTML. Any clue what the author is referring to?

Re: Write HTML Right

#65
post #54

Whilst the spec certainly allows you to ignore closing of a whole range of elements, it's not necessarily the wisest of choices to make. The parser does actually get slower when you fail to close your tags in my experience. Unscientific stats from a recent project where I noticed it: + Document is about 50,000 words in size. About 150 words to a paragraph element, on average. + Converting the entire thing to self-clo…

> For some prettier mark up.

But then if you run it through Prettier it'll add all the closing tags for you :)

Re: Write HTML Right

#67

> A few years ago, I found out I'd been tying my shoes wrong for my entire life. I thought laces came undone easily and didn't usually look very good. At least that's how mine were, and I never paid much attention to anyone else's. It took a couple of weeks to re-train my hands but now I have bows in my laces that look good and rarely come undone. I’m equally interested in this as the HTML. Any clue what the author i…

Lucky you! [1]

https://www.fieggen.com/shoelace/

Specifically:

https://www.fieggen.com/shoelace/grannyknot.htm

An HN favorite:

https://news.ycombinator.com/from?site=fieggen.com

1. https://xkcd.com/1053/

Re: Write HTML Right

#68
post #65
post #54

Whilst the spec certainly allows you to ignore closing of a whole range of elements, it's not necessarily the wisest of choices to make. The parser does actually get slower when you fail to close your tags in my experience. Unscientific stats from a recent project where I noticed it: + Document is about 50,000 words in size. About 150 words to a paragraph element, on average. + Converting the entire thing to self-clo…

> For some prettier mark up. But then if you run it through Prettier it'll add all the closing tags for you :)

If you’re running it through a processor, why it just write markdown and call it a day?

Re: Write HTML Right

#69
post #47

Earlier quoted context omitted.

...and absolutely unreadable for anyone using a screen reader.

This was never true, I believe, and only a theoretical issue invented by the semantic-HTML obsessed. From [1]: “It is sometimes suggested, even by some accessibility advocates, that layout tables are bad for accessibility. In reality, layout tables do not pose inherent accessibility issues.” [1] https://webaim.org/techniques/tables/

yep, then no pb as a layout.
Post reply on HN