Skip to content

Commit 0d6f4ae

Browse files
committed
Refactor prose
1 parent 3c82e9c commit 0d6f4ae

File tree

1 file changed

+17
-10
lines changed

1 file changed

+17
-10
lines changed

readme.md

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010

1111
[**unist**][unist] utility to get the positional info of nodes.
1212

13-
## Installation
13+
## Install
1414

1515
[npm][]:
1616

17-
```bash
17+
```sh
1818
npm install unist-util-position
1919
```
2020

@@ -24,7 +24,7 @@ npm install unist-util-position
2424
var remark = require('remark')
2525
var position = require('unist-util-position')
2626

27-
var tree = remark().parse(['# foo', '', '* bar', ''].join('\n'))
27+
var tree = remark().parse('# foo\n\n* bar\n')
2828

2929
position.start(tree) // => {line: 1, column: 1}
3030
position.end(tree) // => {line: 4, column: 1}
@@ -50,13 +50,18 @@ Get the start or end points in the positional info of `node`.
5050
[`Point`][point] — Filled with `line` (nullable `uint32 >= 1`),
5151
`column` (nullable `uint32 >= 1`), `offset` (nullable `uint32 >= 0`).
5252

53+
Note that in [unist][], `line` and `column` are 1-indexed integers and
54+
`offset` is a 0-indexed integer.
55+
5356
## Contribute
5457

55-
See [`contributing.md` in `syntax-tree/unist`][contributing] for ways to get
58+
See [`contributing.md` in `syntax-tree/.github`][contributing] for ways to get
5659
started.
60+
See [`support.md`][support] for ways to get help.
5761

58-
This organisation has a [Code of Conduct][coc]. By interacting with this
59-
repository, organisation, or community you agree to abide by its terms.
62+
This project has a [Code of Conduct][coc].
63+
By interacting with this repository, organisation, or community you agree to
64+
abide by its terms.
6065

6166
## License
6267

@@ -96,12 +101,14 @@ repository, organisation, or community you agree to abide by its terms.
96101

97102
[npm]: https://docs.npmjs.com/cli/install
98103

104+
[contributing]: https://github.com/syntax-tree/.github/blob/master/contributing.md
105+
106+
[support]: https://github.com/syntax-tree/.github/blob/master/support.md
107+
108+
[coc]: https://github.com/syntax-tree/.github/blob/master/code-of-conduct.md
109+
99110
[unist]: https://github.com/syntax-tree/unist
100111

101112
[node]: https://github.com/syntax-tree/unist#node
102113

103114
[point]: https://github.com/syntax-tree/unist#point
104-
105-
[contributing]: https://github.com/syntax-tree/unist/blob/master/contributing.md
106-
107-
[coc]: https://github.com/syntax-tree/unist/blob/master/code-of-conduct.md

0 commit comments

Comments
 (0)