Open patik opened 9 years ago
The minimum viable code an html5 document needs is:
<!doctype html>
<html>
<title>a</title>
<body>
</body>
</html>
everything else is butter.
and :+1: to handling this now instead of after everyone deploys.
How are we testing this to ensure it still works in all browsers?
Iceboxing this for now, per @lukecharde.
To be clear, to anyone happening upon this issue, even though we are iceboxing, we still believe this issue is important. It will be more important than ever to begin unifying our coding standards for things like this. Especially considering that we will need to be the owners of this content in the end.
The frame buster page could use a couple of improvements. The following items are not only good practices, but they are used in the interactive embed code.
document.write()
which can be harmful.exec()
method will return an array of 1 item if the overall pattern matches, even if a group inside the pattern (in parentheses) doesn't match. The code below that relies on the array having at least 2 items.<head>
element, even if it's empty. I know thatdocument.getElementsByTagName('head')
will work in modern browsers regardless, but I'm not sure about legacy browsers and it doesn't seem worth the minimal bandwidth to leave the element out.I'm opening a PR to address these but I wanted to outline the changes and rationale here.