Doctype html, big diff

Doctype html, big diff
0

#1

I build one widget
And now i’m near finish
but lately i tried to include
<!doctype html>
And there is huge different?
Any advice?


#2

I’m not sure what you mean. If you’re using CodePen, or some other online coding platform, you shouldn’t use a doctype declaration. If you’re building all of the HTML yourself, you only need it on the document being displayed, and not in any templates or partials you include.


#3

I build offline and i didn’t include this default doctype line
And now on the near end i included and it render different


#4

quick google found this … so rather than me read it ill let you go through it and see what it says … as using <!doctype html > or not using it makes a difference to page rendering.
http://www.htmlgoodies.com/html5/markup/the-doctype-tag-and-its-effect-on-page-rendering.html#fbid=nuXimuv45dF