Skip to content

API > wxt/utils/content-script-ui/types > ContentScriptUiOptions

Type alias: ContentScriptUiOptions<TMounted>

ContentScriptUiOptions<TMounted>: ContentScriptPositioningOptions & ContentScriptAnchoredOptions & object

Options shared by integrated, shadow root, and iframe UIs.

position selects "inline", "overlay", or "modal" positioning. zIndex controls the positioning element's stacking level for overlays and modals. alignment is available for overlays.

Type declaration

onRemove

onRemove?: (mounted) => void

Callback called before the UI is removed from the webpage. Use to cleanup your UI, like unmounting your Vue or React apps.

Note that this callback is called only when ui.remove is called - that means it is not called automatically when the anchor is removed, unless you use autoMount.

Parameters

mounted: TMounted | undefined

Type parameters

Parameter
TMounted

Source

packages/wxt/src/utils/content-script-ui/types.ts:14


Generated using typedoc-plugin-markdown and TypeDoc