Skip to content

Commit

Permalink
docs(api.md): emulateMedia example fix (#2100)
Browse files Browse the repository at this point in the history
  • Loading branch information
vsn4ik authored May 4, 2020
1 parent 932d6ba commit ef9eed8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1085,7 +1085,7 @@ await page.dispatchEvent('#source', 'dragstart', { dataTransfer });
await page.evaluate(() => matchMedia('screen').matches));
// → true
await page.evaluate(() => matchMedia('print').matches));
//true
//false

await page.emulateMedia({ media: 'print' });
await page.evaluate(() => matchMedia('screen').matches));
Expand All @@ -1097,7 +1097,7 @@ await page.emulateMedia({});
await page.evaluate(() => matchMedia('screen').matches));
// → true
await page.evaluate(() => matchMedia('print').matches));
//true
//false
```

```js
Expand Down

0 comments on commit ef9eed8

Please sign in to comment.