vue-jsdiff

A javascript text differencing implementation with vue
5,242
Install
npm install vue-jsdiff
Latest Version:1.0.1
License:BSD-2-Clause
Last Updated:Feb 17, 2021
Links: npm
Maintainer: youxam

vue-jsdiff

中文 | English

A javascript text differencing implementation for Vue.

Vue-jsdiff does not provide UI, is an encapsulation of jsdiff. Its API is the same as jsdiff ver. 5.0.0.

Installation

npm install vue-jsdiff --save

Examples

import Diff from 'vue-jsdiff'
export default {
 name: 'example',
 created () {
  console.log(Diff.diffLines('old string', 'new string'))
 }
}

API list

See jsdiff for detailed documents.

  1. diffChars
  2. diffWords
  3. diffWordsWithSpace
  4. diffLines
  5. diffTrimmedLines
  6. diffSentences
  7. diffCss
  8. diffJson
  9. diffArrays
  10. structuredPatch
  11. createTwoFilesPatch
  12. createPatch
  13. applyPatch
  14. applyPatches
  15. parsePatch
  16. merge
  17. convertChangesToDMP
  18. convertChangesToXML
  19. canonicalize

Other

Vue-jsdiff has no plan for constant maitaining.

License

Using BSD License

Related Packages

vue-full-screen-file-drop

Vue component for full screen file drop

16,061 19
bxs-ui-vue

BSX Components

3,870
@~crazy/watcher

对象观察者

1,049
vue-code-diff

代码比对展示(Code comparison display)

144,054 184
vue-cookies-ts

A simple Vue.js plugin for handling browser cookies

41,932 3

Version History

Version Released License
1.0.1 BSD-2-Clause