1. <strong id="7actg"></strong>
    2. <table id="7actg"></table>

    3. <address id="7actg"></address>
      <address id="7actg"></address>
      1. <object id="7actg"><tt id="7actg"></tt></object>

        JsdiffJS文本差分

        聯(lián)合創(chuàng)作 · 2023-09-30 21:43

        Jsdiff是一款實現(xiàn)javascript文本差分的軟件。

        安裝:

        npm install diff

        或者

        bower install jsdiff

        API

        • JsDiff.diffChars(oldStr, newStr[, options]) - diffs two blocks of text, comparing character by character.

          Returns a list of change objects (See below).

        • JsDiff.diffWords(oldStr, newStr[, options]) - diffs two blocks of text, comparing word by word, ignoring whitespace.

          Returns a list of change objects (See below).

        • JsDiff.diffWordsWithSpace(oldStr, newStr[, options]) - diffs two blocks of text, comparing word by word, treating whitespace as significant.

          Returns a list of change objects (See below).

        • JsDiff.diffLines(oldStr, newStr[, options]) - diffs two blocks of text, comparing line by line.

        選擇:

        • ignoreWhitespace: true to ignore leading and trailing whitespace. This is the same as diffTrimmedLines

        • newlineIsToken: true to treat newline characters as separate tokens.  This allows for changes to the newline structure to occur independently of the line content and to be treated as such. In general this is the more human

        • dly form of diffLines and diffLines is better suited for patches and other computer friendly output.

        兼容性:

         Jsdiff支持所有ES3環(huán)境和IE8以下一些已知問題。這些瀏覽器存在一些差異算法,如文字diff和其他可能由于缺乏拆分操作捕獲組支持的失敗操作。

        瀏覽 31
        點贊
        評論
        收藏
        分享

        手機掃一掃分享

        編輯 分享
        舉報
        評論
        圖片
        表情
        推薦
        點贊
        評論
        收藏
        分享

        手機掃一掃分享

        編輯 分享
        舉報
        1. <strong id="7actg"></strong>
        2. <table id="7actg"></table>

        3. <address id="7actg"></address>
          <address id="7actg"></address>
          1. <object id="7actg"><tt id="7actg"></tt></object>
            不花钱就能看的曹逼视频 | 纲手裸乳被爆白浆 | 91免费国产视频 | 日日爱666 | 99久热视频在线 | 成人午夜啪免费视频在线观看软件 | 大鸡巴草逼 | 国产精品国产精品国产 | 美女操逼视频免费观看 | 国产精品秘 久久久久久99 |