Skip to content

Commit 4895d5f

Browse files
authored
Use read dafult export - requiring with CommonJS (#2057)
Suggesting a change that made my local setup work.
1 parent da0c75d commit 4895d5f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/reference-api.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ read(range: Range) => Promise<string[]>
291291

292292
```js
293293
// git commit -m "I did something"
294-
const read = require('@commitlint/read');
294+
const read = require('@commitlint/read').default;
295295

296296
read({edit: true}).then((messages) => console.log(messages));
297297
// => ['I did something\n\n']

0 commit comments

Comments
 (0)