0

Is there any possibility to pass "--disable-web-security" parameter when opening a new web page, as we do in selenium.

Edit:

I was able to get it done by below code
     String[] chromiumArgs = {
                    "--disable-web-security",
                    "--no-sandbox",
                    "--start-maximized",
                    "--ignore-certificate-errors",// Additional options if needed
                    "--PageLoadStrategy.NORMAL"
    
            };
            browser = playwright.chromium().launch(new BrowserType.LaunchOptions().setHeadless(false).setArgs(Arrays.asList(chromiumArgs)));

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.