@@ -1051,7 +1051,7 @@ <h1>JavaScript Garden</h1>
1051
1051
< p > In order to check the type of an object, it is highly recommended to use
1052
1052
< code > Object.prototype.toString</ code > ; as this is the only reliable way of doing so.
1053
1053
As shown in the above type table, some return values of < code > typeof</ code > are not defined
1054
- in the specification; thus, the can across various implementations.</ p >
1054
+ in the specification; thus, they can differ across various implementations.</ p >
1055
1055
< p > Unless checking whether a variable is defined, < code > typeof</ code > should be avoided at
1056
1056
< strong > all costs</ strong > .</ p > </ section > </ article >
1057
1057
@@ -1161,8 +1161,8 @@ <h1>JavaScript Garden</h1>
1161
1161
value does not change the value of the < strong > type</ strong > < code > undefined</ code > .</ p >
1162
1162
< p > Still, in order to compare something against the value of < code > undefined</ code > it is
1163
1163
necessary to retrieve the value of < code > undefined</ code > in the first place.</ p >
1164
- < p > In order to protect code against a possible overwritten < code > undefined</ code > variable a
1165
- , common technique used is to add an additional parameter to the encapsulation
1164
+ < p > In order to protect code against a possible overwritten < code > undefined</ code > variable, a
1165
+ common technique used is to add an additional parameter to the encapsulation
1166
1166
< a href ="#scopes "> anonymous wrapper</ a > , which gets no argument passed to it.</ p >
1167
1167
< pre > < code > var undefined = 123;
1168
1168
(function(something, foo, undefined) {
0 commit comments