# diff3

> A diff3 engine for nodejs

Latest version **0.0.4** (published 2022-07-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install diff3
pnpm add diff3
yarn add diff3
bun add diff3
```

## Health

**Score 23/100 (F)** — status: abandoned.

Positive: has types package; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.4 |
| Published | 2022-07-25 |
| First published | 2016-04-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | separate (@types/diff3) |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 11.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 14 |
| Author | Tyler Wanek & Jacob Watson |
| Maintainers | implausibility, gk-dev |
| Keywords | diff3, diff |

## Links

- npm: https://www.npmjs.com/package/diff3
- Repository: https://github.com/axosoft/diff3
- Homepage: https://github.com/axosoft/diff3#readme
- Issues: https://github.com/axosoft/diff3/issues
- npm.io page: https://npm.io/package/diff3

## Recent versions

- 0.0.4 (latest) — 2022-07-25
- 0.0.3 — 2016-05-26
- 0.0.2 — 2016-05-13
- 0.0.1 — 2016-04-27

## README

# diff3

## Usage
```js
var diff3Merge = require('diff3');
var a = ['a', 'text', 'file'];
var o = ['a', 'test', 'file'];
var b = ['a', 'toasty', 'filtered', 'file'];
var diff3 = diff3Merge(a, o, b);
```

## Output
```JSON
[{
    "ok": ["a"]
}, {
    "conflict": {
        "a": ["text"],
        "aIndex": 1,
        "o": ["test"],
        "oIndex": 1,
        "b": ["toasty", "filtered"],
        "bIndex": 1
    }
}, {
    "ok": ["file"]
}]
```

---
_Source: https://npm.io/package/diff3 · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
