Skip to content

Redirector

Repohttps://github.com/firefox-extensions-declarative/Redirector-declarative
Extension IDredirector@einaregilsson.com

Run python3 build.py. The XPI is located at build/redirector-firefox.xpi.

Thanks to @chuangzhu for making patch this uses.

A single Redirector rule.

Human-readable rule name.
Type: string

Example URL that matches rule.
Type: string

Example result after redirect.
Type: string

Rule validation error, if any. Usually null.
Type: string | null

Pattern to match URLs against.
Type: string

Pattern to exclude from matching.
Type: string

Human-readable explanation of pattern.
Type: string

Target URL to redirect to.
Type: string

Pattern type.
Type: "W" | "R" | "C" | string

  • W: wildcard
  • R: regular expression
  • C: compatibility pattern

How Redirector processes matched groups.
Type: "noProcessing" | string

Whether rule is disabled.
Type: boolean

Whether rule is grouped in Redirector UI.
Type: boolean

Request types this rule applies to.
Type: Array<string>

Common values include "main_frame", "sub_frame", "stylesheet", "script", "image", "xmlhttprequest", and "other".

List of Redirector rules.
Type: Array<Redirect>
Default: []