Skip to content

API > wxt > SidepanelEntrypointOptions

Interface: SidepanelEntrypointOptions

Contents

Extends

Properties

browserStyle

browserStyle?: PerBrowserOption<boolean>

Deprecated

See https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/sidebar_action#syntax

Source

packages/wxt/src/types.ts:695


defaultIcon

defaultIcon?: string | Record<string, string>

Source

packages/wxt/src/types.ts:696


defaultTitle

defaultTitle?: PerBrowserOption<string>

Source

packages/wxt/src/types.ts:697


exclude

exclude?: string[]

List of target browsers to exclude this entrypoint from. Cannot be used with include. You must choose one of the two options.

Default

ts
undefined

Inherited from

BaseEntrypointOptions.exclude

Source

packages/wxt/src/types.ts:553


globalName

globalName?: string | boolean | (entrypoint) => string

The variable name for the IIFE in the JS output bundle.

This option is for content scripts with world=MAIN, and unlisted scripts. It's relevant for scripts that are inserted into the page context where the default IIFE variable name may conflict with an existing variable on the target page. This applies to content scripts with world=MAIN, and others, such as unlisted scripts, that could be dynamically injected into the page with a <script> tag.

Available options:

  • true: automatically generate a name for the IIFE based on the entrypoint name
  • false: Output the IIFE without a variable name, making it anonymous. This is the safest option to avoid conflicts with existing variables on the page. This will become the default in a future version of WXT.
  • string: Use the provided string as the global variable name.
  • function: A function that receives the entrypoint and returns a string to use as the variable name.

Default

ts
true

Inherited from

BaseEntrypointOptions.globalName

Source

packages/wxt/src/types.ts:572


include

include?: string[]

List of target browsers to include this entrypoint in. Defaults to being included in all builds. Cannot be used with exclude. You must choose one of the two options.

Default

ts
undefined

Inherited from

BaseEntrypointOptions.include

Source

packages/wxt/src/types.ts:546


openAtInstall

openAtInstall?: PerBrowserOption<boolean>

Firefox only. See https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/sidebar_action#syntax

Default

ts
false

Source

packages/wxt/src/types.ts:691


Generated using typedoc-plugin-markdown and TypeDoc