Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
removeFromBrowserTitleQueue() for Lightning Experience
Removes a string from a list of titles that rotate in the browser title bar every
three seconds. This method works only in
Lightning console apps.
This method isn’t supported for Lightning Web Components
(LWC).
Arguments
| Name | Type | Description |
|---|---|---|
| title | string | The browser tab title to remove. |
Sample Code
This component has a button that, when pressed, removes a string from a list of titles that rotate in the browser title bar every three seconds.
Component code:
1<aura:component implements="flexipage:availableForAllPageTypes" access="global" >
2 <lightning:workspaceAPI aura:id="workspace" />
3 <lightning:button label="Remove from Browser Title Queue" onclick="{! c.handleRemoveFromBrowserTitleQueue }" />
4</aura:component>Controller code:
1({
2 handleremoveFromBrowserTitleQueue : function(component, event, helper) {
3 var workspaceAPI = component.find("workspace");
4 workspaceAPI.removeFromBrowserTitleQueue({
5 title: "New Browser Title"
6 })
7 .then(function(result){
8 console.log(result);
9 })
10 .catch(function(error) {
11 console.log(error);
12 });
13 }
14})Response
This method returns a promise that, open success, resolves
to true.