docs(chrome-extensions) update headless testing docs (#20643)
Update the documentation according to changes https://bugs.chromium.org/p/chromium/issues/detail?id=1380881
This commit is contained in:
parent
9787de92f3
commit
494497abbf
|
|
@ -224,7 +224,7 @@ const pathToExtension = path.join(__dirname, 'my-extension');
|
||||||
const context = await chromium.launchPersistentContext('', {
|
const context = await chromium.launchPersistentContext('', {
|
||||||
headless: false,
|
headless: false,
|
||||||
args: [
|
args: [
|
||||||
`--headless=chrome`, // the new headless arg
|
`--headless=new`, // the new headless arg for chrome v109+. Use '--headless=chrome' as arg for browsers v94-108.
|
||||||
`--disable-extensions-except=${pathToExtension}`,
|
`--disable-extensions-except=${pathToExtension}`,
|
||||||
`--load-extension=${pathToExtension}`,
|
`--load-extension=${pathToExtension}`,
|
||||||
],
|
],
|
||||||
|
|
@ -239,7 +239,7 @@ context = playwright.chromium.launch_persistent_context(
|
||||||
"",
|
"",
|
||||||
headless=False,
|
headless=False,
|
||||||
args=[
|
args=[
|
||||||
"--headless=chrome", # the new headless arg
|
"--headless=new", # the new headless arg for chrome v109+. Use '--headless=chrome' as arg for browsers v94-108.
|
||||||
f"--disable-extensions-except={path_to_extension}",
|
f"--disable-extensions-except={path_to_extension}",
|
||||||
f"--load-extension={path_to_extension}",
|
f"--load-extension={path_to_extension}",
|
||||||
],
|
],
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue