Create a new browser window.
import * as WorkspacePlatform from '@openfin/workspace-platform';
const workspacePlatform = WorkspacePlatform.getCurrentSync();
const layout = {
content: [
{
type: 'stack',
content: [
{
type: 'component',
componentName: 'view',
componentState: {
name: 'myViewName',
url: 'http://google.com'
}
}
]
}
]
};
const page = {
title: 'myPageTitle',
pageId: 'myPageId',
layout
};
const options: BrowserCreateWindowRequest = {
workspacePlatform {
pages: [page],
title: 'My Window Title',
favicon: 'https://google.com/favicon.ico'
}
};
const window = await workspacePlatform.Browser.createWindow(options);
the browser window creation options
Get a list of all pages that are attached to any running browser window.
import * as WorkspacePlatform from '@openfin/workspace-platform';
const workspacePlatform = WorkspacePlatform.getCurrentSync();
const attachedPages = await workspacePlatform.Browser.getAllAttachedPages();
Get all the Browser Windows that are running in the Workspace Platform.
import * as WorkspacePlatform from '@openfin/workspace-platform';
const workspacePlatform = WorkspacePlatform.getCurrentSync();
const windows = await workspacePlatform.Browser.getAllWindows();
Get the identity of the last focused Browser window.
import * as WorkspacePlatform from '@openfin/workspace-platform';
const workspacePlatform = WorkspacePlatform.getCurrentSync();
const windowIdentity = await workspacePlatform.Browser.getLastFocusedWindow();
Get a unique title for a page.
import * as WorkspacePlatform from '@openfin/workspace-platform';
const workspacePlatform = WorkspacePlatform.getCurrentSync();
const uniqueTitle = await workspacePlatform.Browser.getUniquePageTitle('myTitle');
a prefix for the title.
Synchronously returns a Browser Window object that represents an existing window
of the window
Generated using TypeDoc
Factory for wrapping browser windows and global operations.