Skip to content

Commit

Permalink
v131 (#328)
Browse files Browse the repository at this point in the history
  • Loading branch information
yokoffing authored Nov 1, 2024
1 parent ab5ede0 commit 8026175
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 78 deletions.
33 changes: 11 additions & 22 deletions Fastfox.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Fastfox *
* "Non ducor duco" *
* priority: speedy browsing *
* version: 130 *
* version: 131 *
* url: https://github.com/yokoffing/Betterfox *
***************************************************************************************/

Expand Down Expand Up @@ -45,8 +45,8 @@
// to impact page load performance.
// [EXAMPLE] 100000 = .10s = 100 reflows/second
// [1] https://searchfox.org/mozilla-central/rev/c1180ea13e73eb985a49b15c0d90e977a1aa919c/modules/libpref/init/StaticPrefList.yaml#1824-1834
// [2] https://dev.opera.com/articles/efficient-javascript/?page=3#reflow
// [3] https://dev.opera.com/articles/efficient-javascript/?page=3#smoothspeed
// [2] https://web.archive.org/web/20240115073722/https://dev.opera.com/articles/efficient-javascript/?page=3#reflow
// [3] https://web.archive.org/web/20240115073722/https://dev.opera.com/articles/efficient-javascript/?page=3#smoothspeed
user_pref("content.notify.interval", 100000); // (.10s); default=120000 (.12s)

// PREF: new tab preload
Expand Down Expand Up @@ -99,14 +99,16 @@ user_pref("content.notify.interval", 100000); // (.10s); default=120000 (.12s)
//user_pref("gfx.webrender.software.opengl", true); // LINUX

// PREF: GPU-accelerated Canvas2D
// Use gpu-canvas instead of to skia-canvas.
// Uses Accelerated Canvas2D for hardware acceleration of Canvas2D.
// This provides a consistent acceleration architecture across all platforms
// by utilizing WebGL instead of relying upon Direct2D.
// [WARNING] May cause issues on some Windows machines using integrated GPUs [2] [3]
// Add to your overrides if you have a dedicated GPU.
// [NOTE] Higher values will use more memory.
// [1] https://bugzilla.mozilla.org/show_bug.cgi?id=1741501
// [2] https://github.com/yokoffing/Betterfox/issues/153
// [3] https://github.com/yokoffing/Betterfox/issues/198
//user_pref("gfx.canvas.accelerated", true); // DEFAULT macOS LINUX [FF110]; not compatible with WINDOWS integrated GPUs
//user_pref("gfx.canvas.accelerated", true); // [DEFAULT FF133+]
user_pref("gfx.canvas.accelerated.cache-items", 4096); // default=2048; Chrome=4096
user_pref("gfx.canvas.accelerated.cache-size", 512); // default=256; Chrome=512
user_pref("gfx.content.skia-font-cache-size", 20); // default=5; Chrome=20
Expand Down Expand Up @@ -281,6 +283,8 @@ user_pref("browser.cache.jsbc_compression_level", 3);
// [1] https://hg.mozilla.org/mozilla-central/file/tip/modules/libpref/init/StaticPrefList.yaml#l9652
// [2] https://github.com/arkenfox/user.js/pull/941
user_pref("media.memory_cache_max_size", 65536); // default=8192; AF=65536; alt=131072

// PREF: media cache combine sizes
//user_pref("media.memory_caches_combined_limit_kb", 524288); // DEFAULT; alt=1048576
//user_pref("media.memory_caches_combined_limit_pc_sysmem", 5); // DEFAULT; alt=10; the percentage of system memory that Firefox can use for media caches

Expand Down Expand Up @@ -534,31 +538,16 @@ user_pref("network.predictor.enabled", false);
// PREF: CSS Masonry Layout [NIGHTLY]
// [1] https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Grid_Layout/Masonry_Layout
// [2] https://www.smashingmagazine.com/native-css-masonry-layout-css-grid/
//user_pref("layout.css.grid-template-masonry-value.enabled", true);
user_pref("layout.css.grid-template-masonry-value.enabled", true);

// PREF: Prioritized Task Scheduling API [NIGHTLY]
// [1] https://blog.mozilla.org/performance/2022/06/02/prioritized-task-scheduling-api-is-prototyped-in-nightly/
// [2] https://medium.com/airbnb-engineering/building-a-faster-web-experience-with-the-posttask-scheduler-276b83454e91
// [3] https://github.com/WICG/scheduling-apis/blob/main/explainers/prioritized-post-task.md
// [4] https://wicg.github.io/scheduling-apis/
// [5] https://caniuse.com/mdn-api_taskcontroller
user_pref("dom.enable_web_task_scheduling", true);

// PREF: HTML Sanitizer API [NIGHTLY]
// [1] https://wicg.github.io/sanitizer-api/
// [2] https://caniuse.com/mdn-api_sanitizer
//user_pref("dom.security.sanitizer.enabled", true);

// PREF: WebGPU [HIGHLY EXPERIMENTAL!]
// [WARNING] Do not enable unless you are a web developer!
// [1] https://bugzilla.mozilla.org/show_bug.cgi?id=1746245
// [2] https://developer.chrome.com/docs/web-platform/webgpu/
// [3] https://github.com/gpuweb/gpuweb/wiki/Implementation-Status
// [4] https://hacks.mozilla.org/2020/04/experimental-webgpu-in-firefox/
//user_pref("dom.webgpu.enabled", true);
//user_pref("gfx.webgpu.force-enabled", true); // enforce
// enable WebGPU indirect draws/dispatches:
//user_pref("dom.webgpu.indirect-dispatch.enabled", true);

/****************************************************************************
* SECTION: TAB UNLOAD *
****************************************************************************/
Expand Down
17 changes: 2 additions & 15 deletions Peskyfox.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Peskyfox *
* "Aquila non capit muscas" *
* priority: remove annoyances *
* version: 130 *
* version: 131 *
* url: https://github.com/yokoffing/Betterfox *
* credit: Some prefs are reproduced and adapted from the arkenfox project *
* credit urL: https://github.com/arkenfox/user.js *
Expand Down Expand Up @@ -65,12 +65,6 @@ user_pref("browser.aboutwelcome.enabled", false); // disable Intro screens
// PREF: disable "What's New" toolbar icon [FF69+]
//user_pref("browser.messaging-system.whatsNewPanel.enabled", false);

// PREF: only show List All Tabs icon when needed
// true=always show tab overflow dropdown (FF106+ default)
// false=only display tab dropdown when there are too many tabs
// [1] https://www.ghacks.net/2022/10/19/how-to-hide-firefoxs-list-all-tabs-icon/
user_pref("browser.tabs.tabmanager.enabled", false);

// PREF: new profile switcher
user_pref("browser.profiles.enabled", true);

Expand All @@ -88,12 +82,6 @@ user_pref("toolkit.legacyUserProfileCustomizations.stylesheets", true);
// PREF: add compact mode back to options
user_pref("browser.compactmode.show", true);

// PREF: remove focus indicator for links
// [1] https://www.askvg.com/firefox-tip-restore-classic-dotted-outline-focus-indicator-for-links/
user_pref("browser.display.focus_ring_on_anything", true);
user_pref("browser.display.focus_ring_style", 0);
user_pref("browser.display.focus_ring_width", 0);

// PREF: preferred color scheme for websites
// [SETTING] General>Language and Appearance>Website appearance
// By default, color scheme matches the theme of your browser toolbar (3).
Expand Down Expand Up @@ -178,7 +166,6 @@ user_pref("full-screen-api.warning.timeout", 0); // default=3000
//user_pref("gfx.font_rendering.cleartype_params.rendering_mode", 5);
//user_pref("gfx.font_rendering.cleartype_params.cleartype_level", 100);
//user_pref("gfx.font_rendering.cleartype_params.force_gdi_classic_for_families", "");
//user_pref("gfx.font_rendering.cleartype_params.force_gdi_classic_max_size", 6);
//user_pref("gfx.font_rendering.directwrite.use_gdi_table_loading", false);
// Some users find these helpful:
//user_pref("gfx.font_rendering.cleartype_params.gamma", 1750);
Expand Down Expand Up @@ -250,7 +237,7 @@ user_pref("browser.urlbar.trending.featureGate", false);
// [1] https://bugzilla.mozilla.org/show_bug.cgi?id=1753933#c6
// [2] https://developer.mozilla.org/en-US/docs/Web/Text_fragments
// [3] https://web.dev/articles/text-fragments
user_pref("dom.text_fragments.enabled", true);
//user_pref("dom.text_fragments.enabled", true); // [DEFAULT]

/****************************************************************************
* SECTION: AUTOPLAY *
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Now with support for ESR [128](https://github.com/yokoffing/Betterfox/tree/esr12
## Made for everyday browsing
**A secure, blazing fast browsing experience. Without breakage.**

Betterfox is an opinionated preference list inspired by the [law of diminishing returns](https://web.archive.org/web/20231108092752if_/https://pmctraining.com/site/wp-content/uploads/2018/04/Law-of-Diminishing-Returns-CHART.png) and the [minimum effective dose](https://medium.com/the-mission/less-is-more-the-minimum-effective-dose-e6d56625931e).
Betterfox is an opinionated preference list inspired by the [law of diminishing returns](https://miro.medium.com/v2/resize:fit:1206/1*lcOcxriV_II_lZuXQYLoXg.jpeg) and the [minimum effective dose](https://medium.com/the-mission/less-is-more-the-minimum-effective-dose-e6d56625931e).

## Simple goals
1) **Minimalism:** get what isn't needed out of the way
Expand Down
31 changes: 15 additions & 16 deletions Securefox.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Securefox *
* "Natura non contristatur" *
* priority: provide sensible security and privacy *
* version: 130 *
* version: 131 *
* url: https://github.com/yokoffing/Betterfox *
* credit: Most prefs are reproduced and adapted from the arkenfox project *
* credit urL: https://github.com/arkenfox/user.js *
Expand All @@ -24,7 +24,7 @@
//user_pref("privacy.trackingprotection.enabled", true); // enabled with "Strict"
//user_pref("privacy.trackingprotection.pbmode.enabled", true); // DEFAULT
//user_pref("browser.contentblocking.customBlockList.preferences.ui.enabled", false); // DEFAULT
user_pref("browser.contentblocking.category", "strict");
user_pref("browser.contentblocking.category", "strict"); // [HIDDEN]
//user_pref("privacy.trackingprotection.socialtracking.enabled", true); // enabled with "Strict"
//user_pref("privacy.socialtracking.block_cookies.enabled", true); // DEFAULT
//user_pref("privacy.trackingprotection.cryptomining.enabled", true); // DEFAULT
Expand All @@ -38,6 +38,8 @@ user_pref("browser.contentblocking.category", "strict");
//user_pref("privacy.annotate_channels.strict_list.pbmode.enabled", true); // DEFAULT
//user_pref("privacy.fingerprintingProtection", true); // [FF114+] [ETP FF119+] enabled with "Strict"
//user_pref("privacy.fingerprintingProtection.pbmode", true); // DEFAULT
//user_pref("privacy.bounceTrackingProtection.mode", 1); // [FF131+] [ETP FF133+]
// [1] https://searchfox.org/mozilla-central/source/toolkit/components/antitracking/bouncetrackingprotection/nsIBounceTrackingProtection.idl#11-23

// PREF: query stripping
// Currently uses a small list [1]
Expand Down Expand Up @@ -143,14 +145,6 @@ user_pref("urlclassifier.features.socialtracking.skipURLs", "*.instagram.com, *.
// [6] https://firefox-source-docs.mozilla.org/toolkit/components/antitracking/anti-tracking/cookie-purging/index.html
//user_pref("privacy.purge_trackers.enabled", true); // DEFAULT

// PREF: Bounce Tracking Protection [FF127+]
// A new standardised variant of Cookie Purging that uses heuristics to detect bounce trackers,
// rather than relying on tracker lists.
// [1] https://bugzilla.mozilla.org/show_bug.cgi?id=1895222
// [2] https://groups.google.com/a/mozilla.org/g/dev-platform/c/M6erM0SjPTM
//user_pref("privacy.bounceTrackingProtection.enabled", true);
//user_pref("privacy.bounceTrackingProtection.enableDryRunMode", false); // false enables tracker data purging

// PREF: SameSite Cookies
// Currently, the absence of the SameSite attribute implies that cookies will be
// attached to any request for a given origin, no matter who initiated that request.
Expand All @@ -167,7 +161,7 @@ user_pref("urlclassifier.features.socialtracking.skipURLs", "*.instagram.com, *.
// [8] https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies
// [TEST] https://samesite-sandbox.glitch.me/
//user_pref("network.cookie.sameSite.laxByDefault", true);
user_pref("network.cookie.sameSite.noneRequiresSecure", true);
//user_pref("network.cookie.sameSite.noneRequiresSecure", true); // [DEFAULT FF131+]
//user_pref("network.cookie.sameSite.schemeful", true);

// PREF: Hyperlink Auditing (click tracking)
Expand Down Expand Up @@ -351,6 +345,12 @@ user_pref("browser.xul.error_pages.expert_bad_cert", true);
// [3] https://blog.cloudflare.com/tls-1-3-overview-and-q-and-a/
user_pref("security.tls.enable_0rtt_data", false);

// PREF: enable hybrid post-quantum key exchange
// [1] https://pq.cloudflareresearch.com
// [2] https://github.com/zen-browser/desktop/pull/2275
//user_pref("security.tls.enable_kyber", true);
//user_pref("network.http.http3.enable_kyber", true);

/****************************************************************************
* SECTION: FINGERPRINT PROTECTION (FPP) *
****************************************************************************/
Expand Down Expand Up @@ -394,7 +394,7 @@ user_pref("security.tls.enable_0rtt_data", false);
* SECTION: DISK AVOIDANCE *
****************************************************************************/

// PREF: prevent media cache from writing to disk in Private Browsing
// PREF: set media cache in Private Browsing to in-memory
// [NOTE] MSE (Media Source Extensions) are already stored in-memory in PB
user_pref("browser.privatebrowsing.forceMediaMemoryCache", true);

Expand Down Expand Up @@ -590,8 +590,8 @@ user_pref("browser.search.suggest.enabled", false);
// PREF: disable Firefox Suggest
// [1] https://github.com/arkenfox/user.js/issues/1257
user_pref("browser.urlbar.quicksuggest.enabled", false); // controls whether the UI is shown
user_pref("browser.urlbar.suggest.quicksuggest.sponsored", false); // [FF92+]
user_pref("browser.urlbar.suggest.quicksuggest.nonsponsored", false); // [FF95+]
//user_pref("browser.urlbar.suggest.quicksuggest.sponsored", false); // [FF92+]
//user_pref("browser.urlbar.suggest.quicksuggest.nonsponsored", false); // [FF95+]
// hide Firefox Suggest label in URL dropdown box
user_pref("browser.urlbar.groupLabels.enabled", false);

Expand Down Expand Up @@ -1303,7 +1303,7 @@ user_pref("permissions.default.geo", 2);

// PREF: remove special permissions for certain mozilla domains [FF35+]
// default = resource://app/defaults/permissions
//user_pref("permissions.manager.defaultsUrl", "");
user_pref("permissions.manager.defaultsUrl", "");

// PREF: remove webchannel whitelist
user_pref("webchannel.allowObject.urlWhitelist", "");
Expand Down Expand Up @@ -1399,7 +1399,6 @@ user_pref("network.connectivity-service.enabled", false);
//user_pref("toolkit.telemetry.dap_helper", ""); // [OPTIONAL HARDENING]
//user_pref("toolkit.telemetry.dap_leader", ""); // [OPTIONAL HARDENING]


// PREF: software that continually reports what default browser you are using [WINDOWS]
// [WARNING] Breaks "Make Default..." button in Preferences to set Firefox as the default browser [2].
// [1] https://techdows.com/2020/04/what-is-firefox-default-browser-agent-and-how-to-disable-it.html
Expand Down
18 changes: 5 additions & 13 deletions personal/user-overrides.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ user_pref("browser.sessionstore.restore_pinned_tabs_on_demand", true);
user_pref("browser.sessionhistory.max_total_viewers", 4); // only remember # of pages in Back-Forward cache
user_pref("browser.cache.disk.enable", false); // disable disk cache
user_pref("network.http.max-persistent-connections-per-server", 20); // increase download connections
user_pref("network.buffer.cache.size", 262144); // default=32768; [WARNING] Cannot open HTML files bigger than 4 MB if changed
user_pref("network.buffer.cache.count", 128); // default=24; use bigger packets

/** SECUREFOX ***/
//user_pref("urlclassifier.features.socialtracking.skipURLs", "*.twitter.com, *.twimg.com"); // removed *.instagram.com
Expand Down Expand Up @@ -103,15 +101,13 @@ user_pref("network.trr.mode", 3); // enable TRR (without System fallback)
user_pref("gfx.canvas.accelerated", true); // DEFAULT NON-WINDOWS; enable if not using an integrated GPU
user_pref("browser.startup.preXulSkeletonUI", false); // WINDOWS
user_pref("default-browser-agent.enabled", false); // deny Mozilla monitoring default browser (breaks "Make Default" button)
user_pref("geo.provider.ms-windows-location", false); // [WINDOWS]
user_pref("geo.provider.ms-windows-location", false); // [WINDOWS]
user_pref("pdfjs.defaultZoomValue", "125"); // alt=page-width; PDF zoom level
user_pref("gfx.font_rendering.cleartype_params.rendering_mode", 5);
user_pref("gfx.font_rendering.cleartype_params.cleartype_level", 100);
user_pref("gfx.font_rendering.cleartype_params.force_gdi_classic_for_families", "");
user_pref("gfx.font_rendering.cleartype_params.force_gdi_classic_max_size", 6);
user_pref("gfx.font_rendering.directwrite.use_gdi_table_loading", false);
//user_pref("gfx.font_rendering.cleartype_params.enhanced_contrast", 100);
//user_pref("gfx.font_rendering.cleartype_params.gamma", 898); // 1000-2200; https://www.reddit.com/r/firefox/comments/10ed7o2/comment/j4qar9y/
//user_pref("font.name.serif.x-western", "Roboto Slab"); // serif font
//user_pref("font.name.sans-serif.x-western", "Roboto"); // sans-serif font
//user_pref("font.name.monospace.x-western", "Fira Code"); // monospace font
Expand All @@ -120,17 +116,16 @@ user_pref("gfx.font_rendering.directwrite.use_gdi_table_loading", false);
user_pref("urlclassifier.trackingSkipURLs", ""); // do not allow embedded tweets, Instagram, Reddit, and Tiktok posts
user_pref("urlclassifier.features.socialtracking.skipURLs", ""); // do not allow embedded tweets, Instagram, Reddit, and Tiktok posts
user_pref("browser.search.suggest.enabled", true); // search suggestions
user_pref("browser.urlbar.showSearchSuggestionsFirst", true); // Show search suggestions ahead of browsing history in address bar results"
user_pref("network.connectivity-service.enabled", true); // public wifi
user_pref("network.trr.confirmationNS", "example.com"); // TRR confirmation request
user_pref("browser.urlbar.showSearchSuggestionsFirst", true); // Show search suggestions ahead of browsing history in address bar results
//user_pref("network.connectivity-service.enabled", true); // public wifi
//user_pref("network.trr.confirmationNS", "example.com"); // TRR confirmation request
//user_pref("network.trr.mode", 2); // enable TRR (without System fallback)
//user_pref("browser.startup.preXulSkeletonUI", false); // WINDOWS
user_pref("gfx.font_rendering.cleartype_params.rendering_mode", 5);
user_pref("gfx.font_rendering.cleartype_params.cleartype_level", 100);
user_pref("gfx.font_rendering.cleartype_params.force_gdi_classic_for_families", "");
user_pref("gfx.font_rendering.cleartype_params.force_gdi_classic_max_size", 6);
user_pref("gfx.font_rendering.directwrite.use_gdi_table_loading", false);
//user_pref("gfx.font_rendering.cleartype_params.enhanced_contrast", 100);
user_pref("gfx.font_rendering.cleartype_params.enhanced_contrast", 100);
user_pref("toolkit.legacyUserProfileCustomizations.stylesheets", false); // no need for userChrome
//user_pref("browser.urlbar.suggest.history", true); // Browsing history
//user_pref("browser.urlbar.suggest.bookmark", true); // Bookmarks
Expand All @@ -146,9 +141,6 @@ user_pref("app.update.auto", false); // disable auto-installing Firefox updates
//user_pref("font.name.monospace.x-western", "SF Mono"); // monospace font

/** DELETE IF NOT LINUX LAPTOP ***/
//user_pref("browser.low_commit_space_threshold_mb", 13107); // determine when tabs unload
user_pref("browser.low_commit_space_threshold_percent", 10); // determine when tabs unload (percentage)
//user_pref("middlemouse.contentLoadURL", false); // disable middle mouse click opening links from clipboard
user_pref("network.trr.mode", 2); // enable TRR (with System fallback)
user_pref("network.trr.max-fails", 5); // lower max attempts to use DoH
user_pref("geo.provider.use_geoclue", false); // [LINUX]
Expand Down
Loading

0 comments on commit 8026175

Please sign in to comment.