Skip to content

Commit

Permalink
chery-pick(#16666): docs(dotnet): library-csharp.md - use new() synta…
Browse files Browse the repository at this point in the history
…x everywhere
  • Loading branch information
github-actions[bot] committed Aug 19, 2022
1 parent 1ed3879 commit 08f7365
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docs/src/library-csharp.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,10 @@ using var playwright = await Playwright.CreateAsync();
await using var browser = await playwright.Chromium.LaunchAsync();
var page = await browser.NewPageAsync();
await page.GotoAsync("https://playwright.dev/dotnet");
await page.ScreenshotAsync(new PageScreenshotOptions { Path = "screenshot.png" });
await page.ScreenshotAsync(new()
{
Path = "screenshot.png"
});
```

Now run it.
Expand Down

0 comments on commit 08f7365

Please sign in to comment.