Skip to content

Commit f1ed371

Browse files
committed
Refactor docs
1 parent 20a3623 commit f1ed371

File tree

1 file changed

+21
-24
lines changed

1 file changed

+21
-24
lines changed

readme.md

Lines changed: 21 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ word lists.
3737
## Install
3838

3939
This package is [ESM only][esm].
40-
In Node.js (version 14.14+ and 16.0+), install with [npm][]:
40+
In Node.js (version 16+), install with [npm][]:
4141

4242
```sh
4343
npm install nlcst-normalize
@@ -80,7 +80,7 @@ normalize({
8080

8181
## API
8282

83-
This package exports the identifier [`normalize`][normalize].
83+
This package exports the identifier [`normalize`][api-normalize].
8484
There is no default export.
8585

8686
### `normalize(value[, options])`
@@ -92,9 +92,9 @@ lowercases alphabetical characters (`[A-Z]`).
9292

9393
###### Parameters
9494

95-
* `value` (`string`, [`Node`][node], or `Array<Node>`)
95+
* `value` ([`Array<Node>`][node], `Node`, or `string`)
9696
— word
97-
* `options` ([`Options`][options], optional)
97+
* `options` ([`Options`][api-options], optional)
9898
— configuration
9999

100100
###### Returns
@@ -105,31 +105,28 @@ Normalized word (`string`).
105105

106106
Configuration (TypeScript type).
107107

108-
##### Fields
108+
###### Fields
109109

110-
###### `allowApostrophes`
111-
112-
Do not strip apostrophes (`'`) (`boolean`, default: `false`).
113-
114-
The default is to remove apostrophes.
115-
116-
###### `allowDashes`
117-
118-
Do not strip hyphens (`-`) (`boolean`, default: `false`).
119-
120-
The default is to remove the hyphen-minus character.
110+
* `allowApostrophes` (`boolean`, default: `false`)
111+
— do not strip apostrophes (`'`); the default is to remove apostrophes
112+
* `allowDashes` (`boolean`, default: `false`)
113+
— Do not strip hyphens (`-`); the default is to remove the hyphen-minus
114+
character
121115

122116
## Types
123117

124118
This package is fully typed with [TypeScript][].
125-
It exports the additional types [`Options`][options].
119+
It exports the additional types [`Options`][api-options].
126120

127121
## Compatibility
128122

129-
Projects maintained by the unified collective are compatible with all maintained
123+
Projects maintained by the unified collective are compatible with maintained
130124
versions of Node.js.
131-
As of now, that is Node.js 14.14+ and 16.0+.
132-
Our projects sometimes work with older versions, but this is not guaranteed.
125+
126+
When we cut a new major release, we drop support for unmaintained versions of
127+
Node.
128+
This means we try to keep the current release line, `nlcst-normalize@^3`,
129+
compatible with Node.js 12.
133130

134131
## Related
135132

@@ -166,9 +163,9 @@ abide by its terms.
166163

167164
[downloads]: https://www.npmjs.com/package/nlcst-normalize
168165

169-
[size-badge]: https://img.shields.io/bundlephobia/minzip/nlcst-normalize.svg
166+
[size-badge]: https://img.shields.io/badge/dynamic/json?label=minzipped%20size&query=$.size.compressedSize&url=https://deno.bundlejs.com/?q=nlcst-normalize
170167

171-
[size]: https://bundlephobia.com/result?p=nlcst-normalize
168+
[size]: https://bundlejs.com/?q=nlcst-normalize
172169

173170
[sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg
174171

@@ -204,6 +201,6 @@ abide by its terms.
204201

205202
[node]: https://github.com/syntax-tree/unist#node
206203

207-
[normalize]: #normalizevalue-options
204+
[api-normalize]: #normalizevalue-options
208205

209-
[options]: #options
206+
[api-options]: #options

0 commit comments

Comments
 (0)