Skip to content

Instantly share code, notes, and snippets.

@lucasmz-dev
Last active January 14, 2025 06:25
Show Gist options
  • Save lucasmz-dev/027ef8e39f0c08939b5272d5e0ef0931 to your computer and use it in GitHub Desktop.
Save lucasmz-dev/027ef8e39f0c08939b5272d5e0ef0931 to your computer and use it in GitHub Desktop.
// Designed for arkenfox: https://github.com/arkenfox/user.js/
// MOTTO: This ain't Tor Browser.
// Patches
user_pref("network.dns.preferIPv6", true); // Fixes Firefox's own DNS resolver not preferring IPv6 like expected
// Usability
/// Session Restore
user_pref("browser.startup.page", 3);
user_pref("privacy.clearOnShutdown_v2.historyFormDataAndDownloads", false);
/// Disable wiping browser data on shutdown
user_pref("privacy.sanitize.sanitizeOnShutdown", false);
/// Re-enable disk cache
user_pref("browser.cache.disk.enable", true);
user_pref("privacy.clearOnShutdown.cache", false);
user_pref("privacy.clearOnShutdown_v2.cache", false);
// Security
/// Disable Firefox's built-in password manager
user_pref("signon.rememberSignons", false);
// Privacy
user_pref("privacy.globalprivacycontrol.enabled", true);
user_pref("extensions.pocket.enabled", false);
user_pref("geo.provider.network.url", "https://api.beacondb.net/v1/geolocate"); // Switch to beaconDB as the network location service (instead of Google's!)
user_pref("browser.search.separatePrivateDefault", false); // Use the same search engine for private-browsing as when not
// TODO: How to set the search engine here?
// Performance (Stolen from https://codeberg.org/divested/brace/src/branch/master/brace/usr/lib/firefox/browser/defaults/preferences/userjs-brace.js)
user_pref("browser.tabs.remote.autostart", true);
user_pref("browser.tabs.remote.force-enabled", true);
user_pref("extensions.webextensions.remote", true);
user_pref("gfx.canvas.azure.accelerated", true);
user_pref("gfx.webrender.all", true);
user_pref("gfx.webrender.compositor", true);
user_pref("gfx.webrender.enabled", true);
user_pref("layers.acceleration.force-enabled", true);
user_pref("layers.omtp.enabled", true);
user_pref("media.ffmpeg.vaapi.enabled", true);
user_pref("media.hardware-video-decoding.force-enabled", true);
user_pref("widget.wayland-dmabuf-vaapi.enabled", true);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment