Synchronously returns a Platform object that represents an existing platform.
import * as WorkspacePlatform from '@openfin/workspace-platform';// declare platform identityconst myPlatformIdentity: OpenFin.ApplicationIdentity = { uuid: 'testPlatform', name: 'Test Platform'};// get the platform representing myPlatformIdentityconst platform = WorkspacePlatform.wrapSync(myPlatformIdentity);// do something with platform. e.g. create a windowplatform.createWindow({ layout: { content: [ { type: 'component', componentName: 'Example View', componentState: { name: 'example_view_1' url: 'https://developer.openfin.co/docs/javascript/stable/index.html' } } ] }}); Copy
import * as WorkspacePlatform from '@openfin/workspace-platform';// declare platform identityconst myPlatformIdentity: OpenFin.ApplicationIdentity = { uuid: 'testPlatform', name: 'Test Platform'};// get the platform representing myPlatformIdentityconst platform = WorkspacePlatform.wrapSync(myPlatformIdentity);// do something with platform. e.g. create a windowplatform.createWindow({ layout: { content: [ { type: 'component', componentName: 'Example View', componentState: { name: 'example_view_1' url: 'https://developer.openfin.co/docs/javascript/stable/index.html' } } ] }});
Synchronously returns a Platform object that represents an existing platform.