Skip to content

Commit 682c9df

Browse files
authored
docs: fix typos and improve clarity in README.md (#367)
1 parent d4d2f4d commit 682c9df

File tree

1 file changed

+32
-20
lines changed

1 file changed

+32
-20
lines changed

README.md

Lines changed: 32 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212

1313
# stylelint-webpack-plugin
1414

15-
> This version of stylelint-webpack-plugin only works with webpack 5. For the webpack 4, see the [2.x branch](https://github.com/webpack-contrib/stylelint-webpack-plugin/tree/2.x).
15+
> This version of `stylelint-webpack-plugin` only works with webpack 5. For webpack 4, see the [2.x branch](https://github.com/webpack-contrib/stylelint-webpack-plugin/tree/2.x).
1616
17-
This plugin uses [`stylelint`](https://stylelint.io/) that helps you avoid errors and enforce conventions in your styles.
17+
This plugin uses [`stylelint`](https://stylelint.io/), which helps you avoid errors and enforce conventions in your styles.
1818

1919
## Getting Started
2020

@@ -58,9 +58,9 @@ pnpm add -D stylelint
5858

5959
> [!NOTE]
6060
>
61-
> If you are using Stylelint 13 rather than 14+, you might also need to install `@types/stylelint` as a dev dependency if getting stylelint related type errors.
61+
> If you are using Stylelint 13 rather than 14+, you might also need to install `@types/stylelint` as a dev dependency if you encounter Stylelint-related type errors.
6262
63-
Then add the plugin to your webpack config. For example:
63+
Then add the plugin to your webpack configuration. For example:
6464

6565
```js
6666
const StylelintPlugin = require('stylelint-webpack-plugin');
@@ -74,7 +74,7 @@ module.exports = {
7474

7575
## Options
7676

77-
See [stylelint's options](https://stylelint.io/user-guide/usage/node-api#options) for the complete list of options available. These options are passed through to the `stylelint` directly.
77+
See [stylelint's options](https://stylelint.io/user-guide/usage/node-api#options) for the complete list of available options . These options are passed directly to `stylelint`.
7878

7979
### `cache`
8080

@@ -98,7 +98,7 @@ type cacheLocation = string;
9898

9999
- Default: `node_modules/.cache/stylelint-webpack-plugin/.stylelintcache`
100100

101-
Specify the path to the cache location. Can be a file or a directory.
101+
Specify the path to the cache location. This can be a file or a directory.
102102

103103
### `configFile`
104104

@@ -150,7 +150,7 @@ type extensions = string | Array<string>;
150150

151151
- Default: `['css', 'scss', 'sass']`
152152

153-
Specify extensions that should be checked.
153+
Specify the extensions that should be checked.
154154

155155
### `files`
156156

@@ -162,7 +162,7 @@ type files = string | Array<string>;
162162

163163
- Default: `null`
164164

165-
Specify directories, files, or globs. Must be relative to `options.context`. Directories are traversed recursively looking for files matching `options.extensions`. File and glob patterns ignore `options.extensions`.
165+
Specify directories, files, or globs. Must be relative to `options.context`. Directories are traversed recursively, looking for files matching `options.extensions`. File and glob patterns ignore `options.extensions`.
166166

167167
### `fix`
168168

@@ -188,7 +188,7 @@ type formatter = string | (
188188
189189
- Default: `'string'`
190190
191-
Specify the formatter that you would like to use to format your results. See [formatter option](https://stylelint.io/user-guide/usage/options#formatter).
191+
Specify the formatter you would like to use to format your results. See the [formatter option](https://stylelint.io/user-guide/usage/options#formatter).
192192
193193
### `lintDirtyModulesOnly`
194194
@@ -200,7 +200,7 @@ type lintDirtyModulesOnly = boolean;
200200

201201
- Default: `false`
202202

203-
Lint only changed files, skip lint on start.
203+
Lint only changed files; skip linting on start.
204204

205205
### `stylelintPath`
206206

@@ -224,12 +224,15 @@ type threads = boolean | number;
224224

225225
- Default: `false`
226226

227-
Set to true for an auto-selected pool size based on number of cpus. Set to a number greater than 1 to set an explicit pool size. Set to false, 1, or less to disable and only run in main process.
227+
Set to `true` for an auto-selected pool size based on number of CPUs. Set to a number greater than 1 to set an explicit pool size.
228+
229+
Set to `false`, 1, or less to disable and run only in main process.
228230

229231
### Errors and Warning
230232

231-
**By default the plugin will auto adjust error reporting depending on stylelint errors/warnings counts.**
232-
You can still force this behavior by using `emitError` **or** `emitWarning` options:
233+
**By default, the plugin will automatically adjust error reporting depending on the number of Stylelint errors/warnings.**
234+
235+
You can still force this behavior by using the `emitError` **or** `emitWarning` options:
233236

234237
#### `emitError`
235238

@@ -241,7 +244,7 @@ type emitError = boolean;
241244

242245
- Default: `true`
243246

244-
The errors found will always be emitted, to disable set to `false`.
247+
The errors found will always be emitted. To disable, set to `false`.
245248

246249
#### `emitWarning`
247250

@@ -253,7 +256,7 @@ type emitWarning = boolean;
253256

254257
- Default: `true`
255258

256-
The warnings found will always be emitted, to disable set to `false`.
259+
The warnings found will always be emitted. To disable, set to `false`.
257260

258261
#### `failOnError`
259262

@@ -265,7 +268,7 @@ type failOnError = boolean;
265268

266269
- Default: `true`
267270

268-
Will cause the module build to fail if there are any errors, to disable set to `false`.
271+
Will cause the module build to fail if there are any errors. To disable, set to `false`.
269272

270273
#### `failOnWarning`
271274

@@ -277,7 +280,7 @@ type failOnWarning = boolean;
277280

278281
- Default: `false`
279282

280-
Will cause the module build to fail if there are any warnings, if set to `true`.
283+
Will cause the module build to fail if there are any warnings, when set to `true`.
281284

282285
#### `quiet`
283286

@@ -289,7 +292,7 @@ type quiet = boolean;
289292

290293
- Default: `false`
291294

292-
Will process and report errors only and ignore warnings, if set to `true`.
295+
Will process and report errors only, and ignore warnings, when set to `true`.
293296

294297
#### `outputReport`
295298

@@ -311,9 +314,11 @@ type outputReport =
311314

312315
- Default: `false`
313316

314-
Write the output of the errors to a file, for example a `json` file for use for reporting.
317+
Writes the output of the errors to a file - for example, a `json` file for use for reporting.
318+
315319
The `filePath` is relative to the webpack config: `output.path`.
316-
You can pass in a different formatter for the output file, if none is passed in the default/configured formatter will be used.
320+
321+
You can pass in a different formatter for the output file. If none is passed in the default/configured formatter will be used.
317322

318323
```js
319324
{
@@ -326,6 +331,13 @@ You can pass in a different formatter for the output file, if none is passed in
326331

327332
[Changelog](CHANGELOG.md)
328333

334+
## Contributing
335+
336+
We welcome all contributions!
337+
If you're new here, please take a moment to review our contributing guidelines before submitting issues or pull requests.
338+
339+
[CONTRIBUTING](./.github/CONTRIBUTING.md)
340+
329341
## License
330342

331343
[MIT](./LICENSE)

0 commit comments

Comments
 (0)