From 656a9b365fe9a604a1fc86dee294acb36c41f38b Mon Sep 17 00:00:00 2001 From: Aaron Date: Sun, 20 Apr 2025 21:15:08 -0500 Subject: [PATCH] docs(Content Script UI): Add additional details about when `onRemove` is called --- packages/wxt/src/utils/content-script-ui/types.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/wxt/src/utils/content-script-ui/types.ts b/packages/wxt/src/utils/content-script-ui/types.ts index b8fdd9b2..c75b7782 100644 --- a/packages/wxt/src/utils/content-script-ui/types.ts +++ b/packages/wxt/src/utils/content-script-ui/types.ts @@ -9,6 +9,9 @@ export type ContentScriptUiOptions = ContentScriptPositioningOptions & /** * 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`. */ onRemove?: (mounted: TMounted | undefined) => void; };