@@ -37,7 +37,7 @@ word lists.
37
37
## Install
38
38
39
39
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] [ ] :
41
41
42
42
``` sh
43
43
npm install nlcst-normalize
@@ -80,7 +80,7 @@ normalize({
80
80
81
81
## API
82
82
83
- This package exports the identifier [ ` normalize ` ] [ normalize ] .
83
+ This package exports the identifier [ ` normalize ` ] [ api- normalize] .
84
84
There is no default export.
85
85
86
86
### ` normalize(value[, options]) `
@@ -92,9 +92,9 @@ lowercases alphabetical characters (`[A-Z]`).
92
92
93
93
###### Parameters
94
94
95
- * ` value ` (` string ` , [ ` Node ` ] [ node ] , or ` Array<Node> ` )
95
+ * ` value ` ([ ` Array< Node> ` ] [ node ] , ` Node ` , or ` string ` )
96
96
— word
97
- * ` options ` ([ ` Options ` ] [ options ] , optional)
97
+ * ` options ` ([ ` Options ` ] [ api- options] , optional)
98
98
— configuration
99
99
100
100
###### Returns
@@ -105,31 +105,28 @@ Normalized word (`string`).
105
105
106
106
Configuration (TypeScript type).
107
107
108
- ##### Fields
108
+ ###### Fields
109
109
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
121
115
122
116
## Types
123
117
124
118
This package is fully typed with [ TypeScript] [ ] .
125
- It exports the additional types [ ` Options ` ] [ options ] .
119
+ It exports the additional types [ ` Options ` ] [ api- options] .
126
120
127
121
## Compatibility
128
122
129
- Projects maintained by the unified collective are compatible with all maintained
123
+ Projects maintained by the unified collective are compatible with maintained
130
124
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.
133
130
134
131
## Related
135
132
@@ -166,9 +163,9 @@ abide by its terms.
166
163
167
164
[ downloads ] : https://www.npmjs.com/package/nlcst-normalize
168
165
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
170
167
171
- [ size ] : https://bundlephobia .com/result?p =nlcst-normalize
168
+ [ size ] : https://bundlejs .com/?q =nlcst-normalize
172
169
173
170
[ sponsors-badge ] : https://opencollective.com/unified/sponsors/badge.svg
174
171
@@ -204,6 +201,6 @@ abide by its terms.
204
201
205
202
[ node ] : https://github.com/syntax-tree/unist#node
206
203
207
- [ normalize ] : #normalizevalue-options
204
+ [ api- normalize] : #normalizevalue-options
208
205
209
- [ options ] : #options
206
+ [ api- options] : #options
0 commit comments