Skip to content

Ai-Sasit/capacitor-presentation-api

Repository files navigation

presentation-api

The plugin use to presentation to second monitor

Install

npm install presentation-api
npx cap sync

API

echo(...)

echo(options: { value: string; }) => Promise<{ value: string; }>
Param Type
options { value: string; }

Returns: Promise<{ value: string; }>


openLink(...)

openLink(options: { url: string; }) => Promise<{ success?: any; error?: any; url?: any; }>
Param Type
options { url: string; }

Returns: Promise<{ success?: any; error?: any; url?: any; }>


openRawHtml(...)

openRawHtml(options: { htmlStr: string; }) => Promise<{ success?: any; error?: any; }>
Param Type
options { htmlStr: string; }

Returns: Promise<{ success?: any; error?: any; }>


addListener('onSuccessLoadUrl', ...)

addListener(eventName: 'onSuccessLoadUrl', listenerFunc: (data: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
Param Type
eventName 'onSuccessLoadUrl'
listenerFunc (data: any) => void

Returns: Promise<PluginListenerHandle> & PluginListenerHandle


addListener('onFailLoadUrl', ...)

addListener(eventName: 'onFailLoadUrl', listenerFunc: (data: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
Param Type
eventName 'onFailLoadUrl'
listenerFunc (data: any) => void

Returns: Promise<PluginListenerHandle> & PluginListenerHandle


getDisplays()

getDisplays() => Promise<{ displays: number; }>

Returns: Promise<{ displays: number; }>


Interfaces

PluginListenerHandle

Prop Type
remove () => Promise<void>