Skip to content

Latest commit

 

History

History
44 lines (27 loc) · 883 Bytes

tabs.md

File metadata and controls

44 lines (27 loc) · 883 Bytes

border.tabs API

border.tabs

create()

Creates a new tab.

Parameters:
details:BorderTabOptions Configuration to use when creating the tab.

Returns: A Promise resulting in a BorderTab object.

border.tabs.create({ url: "https://www.gooogle.com/" }).then(tab => {
  console.log(tab.title);
});

remove()

Removes (closes) a browser tab.

Parameters:
id:number The ID of the tab to close.

Returns: A Promise resolving with void once the tab is closed.

border.tabs.remove(tab.id).then(_ => {
  console.log('Tab removed! Yay!')
}

get()

Gets a BorderTab object by its ID.

Parameters:
id:number The ID of the tab to resolve.

Returns: A Promise resolving with a `[BorderTab](https://borderbrx once the tab is