|
8 | 8 | [![Backers][backers-badge]][collective]
|
9 | 9 | [![Chat][chat-badge]][chat]
|
10 | 10 |
|
11 |
| -Calculate the number of nodes in a [**Unist**][unist] tree. |
| 11 | +[**unist**][unist] utility to calculate the number of nodes in a tree. |
12 | 12 |
|
13 |
| -## Installation |
| 13 | +## Install |
14 | 14 |
|
15 | 15 | [npm][]:
|
16 | 16 |
|
@@ -45,15 +45,17 @@ console.log(size(tree.children[0].children[0])) // => 0
|
45 | 45 | ### `size(tree)`
|
46 | 46 |
|
47 | 47 | Calculate the number of nodes in [`node`][node].
|
48 |
| -The result is excluding the given node itself. |
| 48 | +The result is the number of [exclusive descendants][descendant]. |
49 | 49 |
|
50 | 50 | ## Contribute
|
51 | 51 |
|
52 |
| -See [`contributing.md` in `syntax-tree/unist`][contributing] for ways to get |
| 52 | +See [`contributing.md` in `syntax-tree/.github`][contributing] for ways to get |
53 | 53 | started.
|
| 54 | +See [`support.md`][support] for ways to get help. |
54 | 55 |
|
55 |
| -This organisation has a [Code of Conduct][coc]. By interacting with this |
56 |
| -repository, organisation, or community you agree to abide by its terms. |
| 56 | +This project has a [Code of Conduct][coc]. |
| 57 | +By interacting with this repository, organisation, or community you agree to |
| 58 | +abide by its terms. |
57 | 59 |
|
58 | 60 | ## License
|
59 | 61 |
|
@@ -93,10 +95,14 @@ repository, organisation, or community you agree to abide by its terms.
|
93 | 95 |
|
94 | 96 | [author]: https://wooorm.com
|
95 | 97 |
|
| 98 | +[contributing]: https://github.com/syntax-tree/.github/blob/master/contributing.md |
| 99 | + |
| 100 | +[support]: https://github.com/syntax-tree/.github/blob/master/support.md |
| 101 | + |
| 102 | +[coc]: https://github.com/syntax-tree/.github/blob/master/code-of-conduct.md |
| 103 | + |
96 | 104 | [unist]: https://github.com/syntax-tree/unist
|
97 | 105 |
|
98 | 106 | [node]: https://github.com/syntax-tree/unist#node
|
99 | 107 |
|
100 |
| -[contributing]: https://github.com/syntax-tree/unist/blob/master/contributing.md |
101 |
| - |
102 |
| -[coc]: https://github.com/syntax-tree/unist/blob/master/code-of-conduct.md |
| 108 | +[descendant]: https://github.com/syntax-tree/unist#descendant |
0 commit comments