svg-sprite-loader icon indicating copy to clipboard operation
svg-sprite-loader copied to clipboard

ie edge does not support the method "querySelectorAll" of symbolNode

Open lt1129 opened this issue 5 years ago • 1 comments

Bug info: IE edge does not support the method "querySelectorAll" of symbolNode, so there is a js error in IE edge.

My fix suggestion: add this judgement: if (typeof node.querySelectorAll === 'function') {

var evalStylesIEWorkaround = function (node) { var updatedNodes = [];

// Maybe add this judgement,you can fix the bug
if (typeof node.querySelectorAll === 'function') {
  arrayFrom(node.querySelectorAll('style'))
    .forEach(function (style) {
      style.textContent += '';
      updatedNodes.push(style);
    });
}

return updatedNodes;

};

Please tell us about your environment:

  • Node.js version: v12.18.3
  • webpack version: 5.1.3
  • svg-sprite-loader version: 5.0.0
  • OS type & version: IE edge

lt1129 avatar Oct 21 '20 10:10 lt1129

I got the same problem at webpack 3.6.9 svg-sprite-loader:4.1.3 OS type: windows 10 browser:IE11 ,IE edge

xcchcaptain avatar Dec 24 '20 02:12 xcchcaptain