New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

presentation-capacitor

Package Overview
Dependencies
Maintainers
0
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

presentation-capacitor

Capacitor Plugin for presentation api

latest
Source
npmnpm
Version
0.1.6
Version published
Maintainers
0
Created
Source

Presentation API Capacitor Plugin

This Capacitor plugin provides seamless integration with the Presentation API, enabling developers to display content on secondary screens, such as projectors or external displays, directly from their mobile and web applications.

Features

  • Multiple Screen Support: Easily present content on external displays or projectors.
  • Customizable Content: Display custom HTML, videos, or other types of media.
  • Cross-Platform Compatibility: Works on Android and web platforms.
  • Simple Integration: Easily integrate with Capacitor and your existing project.
  • Real-Time Updates: Send real-time content updates to the external screen.

Install

Capacitor VersionPresentation Version
Capacitor v40.0.5
Capacitor v60.1.x
npm install presentation-capacitor
npx cap sync

Example Video (Example App included in repo)

https://github.com/user-attachments/assets/a2dbb1f7-6075-4285-885d-39136bc90d9b

API

open(...)

open(options: OpenOptions) => Promise<OpenResponse>
ParamType
optionsOpenOptions

Returns: Promise<OpenResponse>

sendMessage(...)

sendMessage<T>(message: T) => Promise<T>
ParamType
messageT

Returns: Promise<T>

terminate()

terminate() => Promise<void>

addListener('onSuccessLoadUrl', ...)

addListener(eventName: 'onSuccessLoadUrl', listenerFunc: (data: any) => void) => any
ParamTypeDescription
eventName'onSuccessLoadUrl'
listenerFunc(data: any) => void<br> Works only if type html of url or if browser

Returns: any

addListener('onFailLoadUrl', ...)

addListener(eventName: 'onFailLoadUrl', listenerFunc: (data: any) => void) => any
ParamType
eventName'onFailLoadUrl'
listenerFunc(data: any) => void

Returns: any

addListener('onMessage', ...)

addListener(eventName: 'onMessage', listenerFunc: (data: any) => void) => any
ParamType
eventName'onMessage'
listenerFunc(data: any) => void

Returns: any

getDisplays()

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

Returns: Promise<{ displays: number; }>

Type Aliases

OpenResponse

{ success?: any; error?: any; result?: any }

OpenOptions

{} & ( | { type: 'url'; url: string; } | { type: 'video'; videoOptions: { videoUrl: string; showControls?: boolean; }; } | { type: 'html'; html: string; } )

Keywords

capacitor

FAQs

Package last updated on 03 Mar 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts