Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 4c218de

Browse files
committed
style(*): IE is a real browser, and chakra is pretty solid
- IE9+ do not have issues with Function.prototype.apply() on builtin fns (asked Brian Terlson) (NOTE: there may still be corner cases where builtins will not have `apply()` --- this may need to be reverted on complaint). - HTMLScriptElement#text is an IDL-spec'd attribute, and we use it in all cases --- so the comment was sort of nonsense. - The value of `msie` does not depend on whether the user is using a "real" browser or not. Closes #10242
1 parent 929dd15 commit 4c218de

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

src/Angular.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -155,8 +155,8 @@ if ('i' !== 'I'.toLowerCase()) {
155155
}
156156

157157

158-
var /** holds major version number for IE or NaN for real browsers */
159-
msie,
158+
var
159+
msie, // holds major version number for IE, or NaN if UA is not IE.
160160
jqLite, // delay binding since jQuery could be loaded after us.
161161
jQuery, // delay binding
162162
slice = [].slice,

src/ng/directive/script.js

-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ var scriptDirective = ['$templateCache', function($templateCache) {
4040
compile: function(element, attr) {
4141
if (attr.type == 'text/ng-template') {
4242
var templateUrl = attr.id,
43-
// IE is not consistent, in scripts we have to read .text but in other nodes we have to read .textContent
4443
text = element[0].text;
4544

4645
$templateCache.put(templateUrl, text);

src/ng/parse.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -762,7 +762,7 @@ Parser.prototype = {
762762
ensureSafeObject(context, parser.text);
763763
ensureSafeFunction(fnPtr, parser.text);
764764

765-
// IE stupidity! (IE doesn't have apply for some native functions)
765+
// IE doesn't have apply for some native functions
766766
var v = fnPtr.apply
767767
? fnPtr.apply(context, args)
768768
: fnPtr(args[0], args[1], args[2], args[3], args[4]);

0 commit comments

Comments
 (0)