docs: describe playwright.create in java (#5566)
This commit is contained in:
parent
dc3fd3f6b3
commit
ec9a53495a
|
|
@ -3,6 +3,20 @@
|
||||||
|
|
||||||
Terminates this instance of Playwright, will also close all created browsers if they are still running.
|
Terminates this instance of Playwright, will also close all created browsers if they are still running.
|
||||||
|
|
||||||
|
## method: Playwright.create
|
||||||
|
* langs: java
|
||||||
|
- returns: <[Playwright]>
|
||||||
|
|
||||||
|
Launches new Playwright driver process and connects to it. [`method: Playwright.close`] should be called when the instance is no longer needed.
|
||||||
|
|
||||||
|
```java
|
||||||
|
Playwright playwright = Playwright.create()) {
|
||||||
|
Browser browser = playwright.webkit().launch();
|
||||||
|
Page page = browser.newPage();
|
||||||
|
page.navigate("https://www.w3.org/");
|
||||||
|
playwright.close();
|
||||||
|
```
|
||||||
|
|
||||||
### param: BrowserContext.waitForPage.callback = %%-java-wait-for-event-callback-%%
|
### param: BrowserContext.waitForPage.callback = %%-java-wait-for-event-callback-%%
|
||||||
|
|
||||||
### param: Frame.waitForNavigation.callback = %%-java-wait-for-event-callback-%%
|
### param: Frame.waitForNavigation.callback = %%-java-wait-for-event-callback-%%
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue