ferrum icon indicating copy to clipboard operation
ferrum copied to clipboard

Additional Chrome flag recommendations

Open KieranP opened this issue 4 months ago • 0 comments

Have added the following extra browser flags for Chrome. They disable a bunch of stuff that isn't needed when just loading HTML and exporting to a PDF (things like updating browser components, info bars, desktop notifications, etc). It cuts a tiny amount of time off the startup. I'd suggest adding them as defaults to Ferrum:

# Build on top of https://github.com/rubycdp/ferrum/blob/main/lib/ferrum/browser/options/chrome.rb
browser_options = {
  'allow-pre-commit-input' => nil,
  'disable-component-update' => nil,
  'disable-crash-reporter' => nil,
  'disable-features' => %w[
    AcceptCHFrame
    HttpsUpgrades
    InterestFeedContentSuggestion
    IsolateOrigins
    MediaRouter
    OptimizationHints
    Translate
  ].join(","),
  'disable-field-trial-config' => nil,
  'disable-infobars' => nil,
  'disable-notifications' => nil,
  'disable-search-engine-choice-screen' => nil,
  'disable-smooth-scrolling' => nil,
  'no-default-browser-check' => nil,
  'no-pings' => nil,
}

KieranP avatar Oct 08 '25 02:10 KieranP