2017-01-17 4 views
0

안녕 난 기능이 플러그인 markjs에 포함해야 할 오래된 브라우저 용 플러그인 :지원 markjs 여기에 대한 데모입니다

https://markjs.io/configurator.html

서로 다른 노드 나 단어에서 단어를 강조 표시이 플러그인의 기능이라고 wrapMatchesAcrossElements있다 br 태그 사이에 내가 오래된 브라우저에서 작동하도록이 함수가 필요한 경우이 함수를 지원하는 방법에 도움이 될 수 있습니다. 이전 브라우저의 전체 플러그인을 지원하는 경우 플러그인이 현재 9 이상을 지원합니다.

this 내가 원하는 기능 :

jQuery를 오래된 브라우저 버전의 주요 문제없이 실행할 수도 있지만 6,
key: "wrapMatchesAcrossElements", 
      value: function wrapMatchesAcrossElements(regex, ignoreGroups, filterCb, eachCb, endCb) { 
       var _this6 = this; 
       var matchIdx = ignoreGroups === 0 ? 0 : ignoreGroups + 1; 
       this.getTextNodes(function (dict) { 

        var match = void 0; 
         //while ((match = regex.exec(dict.value)) !== null && match[matchIdx] !== "") { 
         while ((match = XRegExp.exec(dict.value, regex)) !== null && match[matchIdx] !== "") { 

         var start = match.index; 
         if (matchIdx !== 0) { 
          for (var i = 1; i < matchIdx; i++) { 
           start += match[i].length; 
          } 
         } 
         var end = start + match[matchIdx].length; 

         _this6.wrapRangeInMappedTextNode(dict, start, end, function (node) { 
          return filterCb(match[matchIdx], node); 
         }, function (node, lastIndex) { 
          regex.lastIndex = lastIndex; 
          //alert(regex); 
          eachCb(node); 
         }); 
        } 
        endCb(); 
       }); 
      } 
+0

어떤 브라우저가 필요합니까? – dude

+0

인터넷 익스플로러 7은 모두 – jsem

+0

입니다. https://www.freelancer.com/projects/Javascript/improve-javascript-code-support-old/ – dude

답변

0

, 우리는 적극적으로에 나타날 수있는 버그를 수정하지 않는 일반적으로 그들에 jQuery를 테스트하지 않습니다.

마찬가지로 jQuery는 베타 또는 개발자 버전과 같은 시험판 버전의 브라우저에서 버그를 수정하지 않습니다. 브라우저의 시험판에서 jQuery로 버그를 발견하면 버그를 브라우저 공급 업체에보고해야합니다.

Click here for Source: