# vtree

> a realtime tree diffing algorithm

Latest version **0.0.22** (published 2014-11-13) · 0 weekly downloads

## Install

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

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.22 |
| Published | 2014-11-13 |
| First published | 2014-04-19 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 126 |
| Author | Matt Esch |
| Maintainers | mattesch |

## Links

- npm: https://www.npmjs.com/package/vtree
- Repository: https://github.com/Matt-Esch/vtree
- Issues: https://github.com/Matt-Esch/vtree/issues
- npm.io page: https://npm.io/package/vtree

## Dependencies (2)

- [is-object](https://npm.io/package/is-object.md) ^0.1.2
- [x-is-array](https://npm.io/package/x-is-array.md) ^0.1.0

## Recent versions

- 0.0.22 (latest) — 2014-11-13
- 0.0.21 — 2014-10-05
- 0.0.20 — 2014-08-24
- 0.0.19 — 2014-07-29
- 0.0.18 — 2014-07-29
- 0.0.17 — 2014-07-29
- 0.0.16 — 2014-07-23
- 0.0.15 — 2014-07-22
- 0.0.14 — 2014-07-19
- 0.0.5 — 2014-07-12
- 0.0.4 — 2014-06-08
- 0.0.3 — 2014-06-02
- 0.0.2 — 2014-05-27
- 0.0.1 — 2014-04-19

## README

# vtree

A realtime tree diffing algorithm

## Motivation

`vtree` currently exists as part of `virtual-dom`. It is used for imitating
diff operations between two `vnode` structures that imitate the structure of
the active DOM node structure in the browser.

## Example

```js
var VNode = require("vtree/vnode")
var diff = require("vtree/diff")

var leftNode = new VNode("div")
var rightNode = new VNode("text")

var patches = diff(leftNode, rightNode)
/*
  -> {
    a: lefNode,
    0: vpatch<REPLACE>(rightNode) // a replace operation for the first node
  }
*/
```

## Installation

`npm install vtree`

## Contributors

 - Matt Esch

## MIT Licenced

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