Post a message to the webview.
The JS environment inside the sidebar view also has two methods,
iina.postMessage
and iina.onMessage
, to exchange data with the plugin script.
See API in Web Views for more information.
The message name.
The message data.
Register a listener for messages posted by the sidebar view.
The JS environment inside the window also has two methods,
iina.postMessage
and iina.onMessage
, to exchange data with the plugin script.
See API in Web Views for more information.
The message name.
The callback to be called when a message with the given name is received.
Generated using TypeDoc
The
SidebarView
module provides a way to display custom content in the sidebar. The content is rendered in a webview, therefore you can load webpages, display information such as lyrics, or additional playback controls.You should add a
sidebarTab
field in the plugin Info.json when using this module:The webview has its own JavaScript context, which cannot access the IINA API directly. It can only communicate with the plugin script via
iina.postMessage
andiina.onMessage
to exchange data. See API in Web Views for more information.Available In Entry
Main only.