Skip to content

Commit 54f2883

Browse files
authored
Merge pull request #1260 from gpoole/patch-1
feat(docs): replace npm@<7 with yarn
2 parents 5f9e457 + 4dbc4b7 commit 54f2883

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

readme.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,15 @@ This can be achieved by:
2929

3030
And both pin/lock to the same version.
3131

32-
# npm@<7
32+
# Yarn
3333

34-
`npm@<7` does not automatically install `peerDependencies`,
34+
Yarn does not automatically install `peerDependencies`,
3535
so if that's what you're using, install them manually.
3636
Here is an example, but use it only for reference,
3737
because your decisions regarding version ranges and range specifiers may vary.
3838

3939
```
40-
npm install --save-dev \
40+
yarn add --dev \
4141
typescript@\* \
4242
eslint@^8.0.1 \
4343
eslint-plugin-promise@^6.0.0 \

src/index.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -367,11 +367,11 @@ test('Exported rule values do not reference eslint-config-standard ones', (t) =>
367367
}
368368
})
369369

370-
test('npm install args in readme satisfy peerDeps', async (t) => {
370+
test('yarn install args in readme satisfy peerDeps', async (t) => {
371371
const { pkgJson, pkgPath, ourPeerDeps } = await getPkgDetails()
372372
const readme = (await readFile(resolve(pkgPath, '..', 'readme.md'))).toString()
373-
const match = readme.match(/```\n(npm install .*?)```/s)
374-
if (match === null) throw new Error()
373+
const match = readme.match(/```\n(yarn add .*?)```/s)
374+
if (match === null) throw new Error("couldn't find yarn add")
375375
if (match.length === 0) throw new Error('failed to find code block')
376376
if (match.length > 2) throw new Error('matched multiple code blocks')
377377
const installArgRanges = Object.fromEntries(

0 commit comments

Comments
 (0)