API / wxt/utils/content-script-ui/types / ContentScriptAnchoredOptions
Interface: ContentScriptAnchoredOptions
Source: packages/wxt/src/utils/content-script-ui/types.ts:99
Contents
Properties
anchor?
optionalanchor?:string|Element| (() =>string|Element|null|undefined) |null
Source: packages/wxt/src/utils/content-script-ui/types.ts:105
A CSS selector, XPath expression, element, or function that returns one of the three. Along with append, the anchor dictates where in the page the UI will be added.
append?
optionalappend?:ContentScriptAppendMode| ((anchor,ui) =>void)
Source: packages/wxt/src/utils/content-script-ui/types.ts:122
In combination with anchor, decide how to add the UI to the DOM.
"last"(default) - Add the UI as the last child of theanchorelement"first"- Add the UI as the first child of theanchorelement"replace"- Replace theanchorelement with the UI."before"- Add the UI as the sibling before theanchorelement"after"- Add the UI as the sibling after theanchorelement(anchor, ui) => void- Customizable function that let's you add the UI to the DOM
Generated using typedoc-plugin-markdown and TypeDoc