Skip to content

Pass in custom chromium prefs (enable developer mode by default) #2899

Closed

Description

@aklinker1

Is this a feature request or a bug?

Feature request.

What is the current behavior?

Currently, web-ext uses [email protected], but v1.1.0 was just released, with a fix to make the prefs option work. This enables us to set custom preferences for the profile, including extensions.ui.developer_mode, which would enable developer mode by default when using web-ext, which is super convenient during development.

import { launch } from 'chrome-launcher';

launch({
  prefs: {
    extensions: {
      ui: {
        developer_mode: true,
      },
    },
  },
});

What is the expected or desired behavior?

Just like the --pref for firefox, it would be awesome if we could add --chromium-pref to the CLI and chromiumPrefs to the JS API. Or at least enable extensions.ui.developer_mode by default. I always have to toggle the setting when developing an extension before debugging the background in chrome.

This might also be a solution for #2874.

I'd be happy to submit a PR, but I can't get tests to pass after upgrading chrome-launcher, there's a error with the watcher that I can't figure out :/

Version information (for bug reports)

  • Firefox version: deved 119.0b2
  • Your OS and version: MacOS Ventura 13.4.1c
  • Paste the output of these commands:
v18.16.1
9.5.1 
7.8.0

Activity

  1. Rob--W commented on Oct 3, 2023

    @Rob--W
    Member

    Neat. I am supportive of setting this flag by default.

    If you have something almost working, you could also create a PR and ask for feedback.

  2. aklinker1 commented on Oct 3, 2023

    @aklinker1
    ContributorAuthor

    Nice, I wanted to make sure this was something that would be accepted before I put any more work into it. I'll open a PR sometime soon.

  3. aklinker1 commented on Oct 15, 2023

    @aklinker1
    ContributorAuthor

    @Rob--W I got the tests working! PR opened.

  4. pirate commented on May 29, 2025

    @pirate

    Image

    Looks like chromium is removing some of the prefs setting APIs, is mozilla keeping them?

  5. Rob--W commented on May 29, 2025

    @Rob--W
    Member

    Firefox still supports setting prefs.

    The PR that was abandoned before introduced the feature via a Preferences file directly in the profile directory. I think that the approach would still work.

  6. PatrykKuniczak commented on May 23, 2026

    @PatrykKuniczak
    Contributor

    @Rob--W Close this, fixed by #3664

  7. PatrykKuniczak commented on Oct 10, 2026

    @PatrykKuniczak
    Contributor

    @Rob--W Let's close this one 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Fields

Priority

None yet

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions