Kaynağa Gözat

fix(IE8): fix for IE8 error on using isUndefined function

Using isUndefined on console object in IE8 will throw an error.
This reverts to using `typeof console === 'undefined'.

Closes #280
Estevao Soares dos Santos 8 yıl önce
ebeveyn
işleme
561dc5f155

+ 2 - 1
dist/showdown.js

@@ -716,7 +716,8 @@ showdown.helper.replaceRecursiveRegExp = function (str, replacement, left, right
 /**
  * POLYFILLS
  */
-if (showdown.helper.isUndefined(console)) {
+// use this instead of builtin is undefined for IE8 compatibility
+if (typeof(console) === 'undefined') {
   console = {
     warn: function (msg) {
       'use strict';

Dosya farkı çok büyük olduğundan ihmal edildi
+ 0 - 0
dist/showdown.js.map


Dosya farkı çok büyük olduğundan ihmal edildi
+ 0 - 0
dist/showdown.min.js


Dosya farkı çok büyük olduğundan ihmal edildi
+ 0 - 0
dist/showdown.min.js.map


+ 2 - 1
src/helpers.js

@@ -254,7 +254,8 @@ showdown.helper.replaceRecursiveRegExp = function (str, replacement, left, right
 /**
  * POLYFILLS
  */
-if (showdown.helper.isUndefined(console)) {
+// use this instead of builtin is undefined for IE8 compatibility
+if (typeof(console) === 'undefined') {
   console = {
     warn: function (msg) {
       'use strict';

Bu fark içinde çok fazla dosya değişikliği olduğu için bazı dosyalar gösterilmiyor