Live data from Hacker News

Htmlshell - generate HTML skeletons

htmlshell.com

1–10 of 30 posts

Re: Htmlshell - generate HTML skeletons

#3
Why do so many people still use redundant HTML tags?

The opening and closing body and head tags aren't needed, nether is the closing html tag. It doesn't make that much difference to the page as a whole but it adds another level of indenting to your code and makes it more complicated than it needs to be.

Re: Htmlshell - generate HTML skeletons

#4

Why do so many people still use redundant HTML tags? The opening and closing body and head tags aren't needed, nether is the closing html tag. It doesn't make that much difference to the page as a whole but it adds another level of indenting to your code and makes it more complicated than it needs to be.

Seriously!?!

Re: Htmlshell - generate HTML skeletons

#5
It's interesting. It would be helpful to me if it included a set of simple templates for different basic css layouts.

e.g. box centered in the center of the screen, three column fixed, two column flexible, etc.

here's a page with a whole listing of example css layouts. http://www.maxdesign.com.au/articles/css-layouts/

Re: Htmlshell - generate HTML skeletons

#6
The 'autorun Javascript' at the bottom would be better of in a directly run anonymous function to avoid polluting the global scope with an 'autorun' function. Also, the 'On page loaded' example is not really needed. Any Javascript included at the very last in the page will run automatically on 'page load'.

Re: Htmlshell - generate HTML skeletons

#7

Just what I need to make a little one-off JavaScript app. To be more DRY, shouldn't the "Autorun JavaScript" make use of selected JavaScript libraries (i.e. jQuery if possible)?

I agree.

Moreover, html5boilerplate recommends NOT to include the /1/ query: http://html5boilerplate.com/html5boilerplate-site/built/en_U...

Re: Htmlshell - generate HTML skeletons

#8

Why do so many people still use redundant HTML tags? The opening and closing body and head tags aren't needed, nether is the closing html tag. It doesn't make that much difference to the page as a whole but it adds another level of indenting to your code and makes it more complicated than it needs to be.

The president of the Federation in Star Trek VI said it best:

"Let us redefine progress to mean that just because we can do a thing, it does not necessarily mean we must do that thing."

Other than the initial level of indenting, which is basically a non-issue for most people I suspect, there just isn't any reason to omit tags like this.

At the same time, they make the markup clearer, and help a reader quickly delineate between two important sections of the document. Therefore, since they provide at least a very small positive benefit, it is perfectly reasonable, IMHO, to include them.

Re: Htmlshell - generate HTML skeletons

#9

Why do so many people still use redundant HTML tags? The opening and closing body and head tags aren't needed, nether is the closing html tag. It doesn't make that much difference to the page as a whole but it adds another level of indenting to your code and makes it more complicated than it needs to be.

Probably the most accurate answer to your question is: Because so many people don't know they are not required. (I certainly was in that category until about 5 minutes ago)

But even now knowing that info... I will continue to use them. Yes, it adds another level of indenting... but personally I prefer that. Text that is without a left margin tends to be a little harder to read. I also like to have a visual grouping of the elements. I think I would disagree that it "makes it more complicated" to have those tags.

Re: Htmlshell - generate HTML skeletons

#10
post #7

Just what I need to make a little one-off JavaScript app. To be more DRY, shouldn't the "Autorun JavaScript" make use of selected JavaScript libraries (i.e. jQuery if possible)?

I agree. Moreover, html5boilerplate recommends NOT to include the /1/ query: http://html5boilerplate.com/html5boilerplate-site/built/en_U...

Actually what would really be neat is if it uses an included library if one is linked (e.g. jQuery $(function(){...});) and the code shown wrapped in an anonymous function otherwise (function(){...})();
Post reply on HN