Hacker News new | ask | show | jobs
by reaperducer 2651 days ago
I do it because it feels right and logical. If something has a start, it should have an end. If you’re making a <div> that is only going to be used as a spacer with styling, you wouldn’t just do a <div> and leave it hanging.
1 comments

You are talking about closing tags. I'm talking about self closing tags.

One should never use an element as a spacer tag. That's 1990s styling at best.

You are talking about closing tags. I'm talking about self closing tags.

I am, too. My point is that in my mind it feels right to close all tags, either with a closing tag or self-closing it with a /.

One should never use an element as a spacer tag.

One should never use “never” in programming. You are incapable of knowing every possible circumstance someone else is working in.

That's 1990s styling at best.

I built and sold several web sites in the 90’s. That’s not how it was done. It was worse.

You are putting the slash in because it feels good but the specification does not do that. You are playing with fire.

Despite your circumstance, the reason for spacer divs, and other such things, are relics of the past and such reasons no longer exist. Using them now is beyond silly.