File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change 2
2
3
3
Diff two [ ** Unist** ] [ unist ] trees.
4
4
5
+ Based on the [ ` vtree ` ] [ vtree ] diffing algorithm in [ ` virtual-dom ` ] [ vdom ] ,
6
+ but for Unist.
7
+
8
+ One caveat is that “Unist” does not support keys. Keys are what allow
9
+ performant reordering of children. To deal with that, ` unist-diff ` uses
10
+ “synthetic” keys based on the properties on nodes (excluding their value
11
+ or their children). This is not ideal but it’s better than nothing.
12
+ Let’s see how it goes!
13
+
5
14
## Installation
6
15
7
16
[ npm] [ ] :
@@ -193,3 +202,7 @@ following properties:
193
202
[ propsdiff ] : #propsdiff
194
203
195
204
[ movediff ] : #movediff
205
+
206
+ [ vtree ] : https://github.com/Matt-Esch/virtual-dom/tree/master/vtree
207
+
208
+ [ vdom ] : https://github.com/Matt-Esch/virtual-dom
You can’t perform that action at this time.
0 commit comments