browser.new_tab

def new_tab(self, url: str, is_wait_complete: bool = True, timeout: int = 30) -> BrowserTab

Open a new tab in the current browser.

Parameters:
url[Required]: str
   Url string, the target site url, eg.: https://www.bing.com.
is_wait_complete: bool
   is_wait_complete, whether to wait for the tab to complete loading, the default value is True.
timeout: int
   Timeout for the operation, the unit is second, and the default value is 30 seconds.

Returns:
BrowserTab object, you can execute following operations in the browser tab: find_element, find_elements, close, refresh and so on.

Example:


from clicknium import clicknium as cc

_tab = cc.chrome.open("https://www.bing.com/")

# get tab's browser
_browser = _tab.browser

# new tab
_browser.new_tab("https://www.bing.com/")
What are your feelings
Updated on 29 August 2023