Skip to content

Commit 653d483

Browse files
authored
docs: add firefox-stable channel documentation (#6328)
Fixes #5993
1 parent fe94dc5 commit 653d483

File tree

3 files changed

+55
-7
lines changed

3 files changed

+55
-7
lines changed

docs/src/api/class-browsertype.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ Whether to run browser in headless mode. More details for
214214
[`option: devtools`] option is `true`.
215215

216216
### option: BrowserType.launch.channel
217-
- `channel` <[BrowserChannel]<"chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary">>
217+
- `channel` <[BrowserChannel]<"chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary"|"firefox-stable">>
218218

219219
Browser distribution channel. Read more about using [Google Chrome and Microsoft Edge](./browsers.md#google-chrome--microsoft-edge).
220220

@@ -327,7 +327,7 @@ Whether to run browser in headless mode. More details for
327327
[`option: devtools`] option is `true`.
328328

329329
### option: BrowserType.launchPersistentContext.channel
330-
- `channel` <[BrowserChannel]<"chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary">>
330+
- `channel` <[BrowserChannel]<"chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary"|"firefox-stable">>
331331

332332
Browser distribution channel. Read more about using [Google Chrome and Microsoft Edge](./browsers.md#google-chrome--microsoft-edge).
333333

@@ -434,7 +434,7 @@ Whether to run browser in headless mode. More details for
434434
Port to use for the web socket. Defaults to 0 that picks any available port.
435435

436436
### option: BrowserType.launchServer.channel
437-
- `channel` <[BrowserChannel]<"chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary">>
437+
- `channel` <[BrowserChannel]<"chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary"|"firefox-stable">>
438438

439439
Browser distribution channel. Read more about using [Google Chrome and Microsoft Edge](./browsers.md#google-chrome--microsoft-edge).
440440

docs/src/browsers.md

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,55 @@ on when to opt into stable channels, refer to the [Google Chrome & Microsoft Edg
2222
## Firefox
2323

2424
Playwright's Firefox version matches the recent [Firefox Beta](https://www.mozilla.org/en-US/firefox/channel/desktop/)
25-
build.
25+
build.
26+
27+
### Firefox-Stable
28+
29+
Playwright team maintains a Playwright Firefox version that matches the latest Firefox Stable, a.k.a. `firefox-stable`.
30+
31+
Using `firefox-stable` is a 2-steps process:
32+
33+
1. Installing `firefox-stable` with Playwright CLI.
34+
```sh js
35+
$ npx playwright install firefox-stable
36+
```
37+
38+
```sh java
39+
$ mvn exec:java -e -Dexec.mainClass=com.microsoft.playwright.CLI -Dexec.args="install firefox-stable"
40+
```
41+
42+
```sh python
43+
$ playwright install firefox-stable
44+
```
45+
46+
2. Using `firefox-stable` channel when launching browser.
47+
```js
48+
const { firefox } = require('playwright');
49+
const browser = await firefox.launch({
50+
channel: 'firefox-stable'
51+
});
52+
```
53+
54+
```java
55+
import com.microsoft.playwright.*;
56+
57+
public class Example {
58+
public static void main(String[] args) {
59+
try (Playwright playwright = Playwright.create()) {
60+
BrowserType firefox = playwright.firefox();
61+
Browser browser = firefox.launch(new BrowserType.LaunchOptions().setChannel("firefox-stable"));
62+
}
63+
}
64+
}
65+
```
66+
67+
```python async
68+
browser = await playwright.firefox.launch(channel="firefox-stable")
69+
```
70+
71+
```python sync
72+
browser = playwright.firefox.launch(channel="firefox-stable")
73+
```
2674
2775
## WebKit
2876

types/types.d.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6768,7 +6768,7 @@ export interface BrowserType<Unused = {}> {
67686768
* Browser distribution channel. Read more about using
67696769
* [Google Chrome and Microsoft Edge](https://playwright.dev/docs/browsers#google-chrome--microsoft-edge).
67706770
*/
6771-
channel?: "chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary";
6771+
channel?: "chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary"|"firefox-stable";
67726772

67736773
/**
67746774
* Enable Chromium sandboxing. Defaults to `true`.
@@ -7098,7 +7098,7 @@ export interface BrowserType<Unused = {}> {
70987098
* Browser distribution channel. Read more about using
70997099
* [Google Chrome and Microsoft Edge](https://playwright.dev/docs/browsers#google-chrome--microsoft-edge).
71007100
*/
7101-
channel?: "chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary";
7101+
channel?: "chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary"|"firefox-stable";
71027102

71037103
/**
71047104
* Enable Chromium sandboxing. Defaults to `true`.
@@ -10799,7 +10799,7 @@ export interface LaunchOptions {
1079910799
* Browser distribution channel. Read more about using
1080010800
* [Google Chrome and Microsoft Edge](https://playwright.dev/docs/browsers#google-chrome--microsoft-edge).
1080110801
*/
10802-
channel?: "chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary";
10802+
channel?: "chrome"|"chrome-beta"|"chrome-dev"|"chrome-canary"|"msedge"|"msedge-beta"|"msedge-dev"|"msedge-canary"|"firefox-stable";
1080310803

1080410804
/**
1080510805
* Enable Chromium sandboxing. Defaults to `false`.

0 commit comments

Comments
 (0)