Skip to content

Instantly share code, notes, and snippets.

@AlexanderOMara
Last active January 24, 2016 08:29
Show Gist options
  • Save AlexanderOMara/b8a118613be73545c1ea to your computer and use it in GitHub Desktop.
Save AlexanderOMara/b8a118613be73545c1ea to your computer and use it in GitHub Desktop.
this in strict mode
<!DOCTYPE html>
<html>
<head>
<title>this and strict mode</title>
</head>
<body>
<script>
'use strict';
alert('this === window: ' + (this === window));
</script>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<title>this and strict mode</title>
</head>
<body>
<script>
'use strict';
alert('this: ' + this);
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment