kiến thức Tổng hợp những addon chất cho Firefox / Chromium

@toi la gay :sosad: có vẻ không giảm được nhiều ram lắm nhưng giảm được kha khá process, từ 14-15 xuống 8-9 là cũng ok rồi
wWNZUYE.png
Vậy thì áp dụng thêm nữa xem sao, đây là tối ưu giảm RAM cực đoan và có lẽ là hết cỡ luôn rồi :D
Code:
user_pref("dom.ipc.processCount.webIsolated", 1);
user_pref("fission.webContentIsolationStrategy", 0);
user_pref("identity.fxaccounts.enabled", false);
user_pref("extensions.pocket.enabled", false);
user_pref("accessibility.force_disabled", 1);
user_pref("fission.autostart", false);
user_pref("dom.ipc.processCount", 1);
user_pref("nglayout.initialpaint.delay", 2000);
user_pref("nglayout.initialpaint.delay_in_oopif", 2000);
// Enable Multi-Account Container
user_pref("privacy.userContext.enabled", true); //enable Multi-Account Container
user_pref("privacy.userContext.ui.enabled", true); //enable Multi-Account Container

/*** [SECTION 0200]: GEOLOCATION / LANGUAGE / LOCALE ***/
user_pref("_user.js.parrot", "0200 syntax error: the parrot's definitely deceased!");
/* 0201: use Mozilla geolocation service instead of Google if permission is granted [FF74+]
 * Optionally enable logging to the console (defaults to false) ***/
user_pref("geo.provider.network.url", "https://location.services.mozilla.com/v1/geolocate?key=%MOZILLA_API_KEY%");
   // user_pref("geo.provider.network.logging.enabled", true); // [HIDDEN PREF]
/* 0202: disable using the OS's geolocation service ***/
user_pref("geo.provider.ms-windows-location", false); // [WINDOWS]
user_pref("geo.provider.use_corelocation", false); // [MAC]
user_pref("geo.provider.use_gpsd", false); // [LINUX]
user_pref("geo.provider.use_geoclue", false); // [FF102+] [LINUX]

/*** [SECTION 0300]: QUIETER FOX ***/
user_pref("_user.js.parrot", "0300 syntax error: the parrot's not pinin' for the fjords!");
/** RECOMMENDATIONS ***/
/* 0320: disable recommendation pane in about:addons (uses Google Analytics) ***/
user_pref("extensions.getAddons.showPane", false); // [HIDDEN PREF]
/* 0321: disable recommendations in about:addons' Extensions and Themes panes [FF68+] ***/
user_pref("extensions.htmlaboutaddons.recommendations.enabled", false);
/* 0322: disable personalized Extension Recommendations in about:addons and AMO [FF65+]
 * [NOTE] This pref has no effect when Health Reports (0331) are disabled
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to make personalized extension recommendations
 * [1] https://support.mozilla.org/kb/personalized-extension-recommendations ***/
user_pref("browser.discovery.enabled", false);

/** TELEMETRY ***/
/* 0330: disable new data submission [FF41+]
 * If disabled, no policy is shown or upload takes place, ever
 * [1] https://bugzilla.mozilla.org/1195552 ***/
user_pref("datareporting.policy.dataSubmissionEnabled", false);
/* 0331: disable Health Reports
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to send technical... data ***/
user_pref("datareporting.healthreport.uploadEnabled", false);
/* 0332: disable telemetry
 * The "unified" pref affects the behavior of the "enabled" pref
 * - If "unified" is false then "enabled" controls the telemetry module
 * - If "unified" is true then "enabled" only controls whether to record extended data
 * [NOTE] "toolkit.telemetry.enabled" is now LOCKED to reflect prerelease (true) or release builds (false) [2]
 * [1] https://firefox-source-docs.mozilla.org/toolkit/components/telemetry/telemetry/internals/preferences.html
 * [2] https://medium.com/georg-fritzsche/data-preference-changes-in-firefox-58-2d5df9c428b5 ***/
user_pref("toolkit.telemetry.unified", false);
user_pref("toolkit.telemetry.enabled", false); // see [NOTE]
user_pref("toolkit.telemetry.server", "data:,");
user_pref("toolkit.telemetry.archive.enabled", false);
user_pref("toolkit.telemetry.newProfilePing.enabled", false); // [FF55+]
user_pref("toolkit.telemetry.shutdownPingSender.enabled", false); // [FF55+]
user_pref("toolkit.telemetry.updatePing.enabled", false); // [FF56+]
user_pref("toolkit.telemetry.bhrPing.enabled", false); // [FF57+] Background Hang Reporter
user_pref("toolkit.telemetry.firstShutdownPing.enabled", false); // [FF57+]
/* 0333: disable Telemetry Coverage
 * [1] https://blog.mozilla.org/data/2018/08/20/effectively-measuring-search-in-firefox/ ***/
user_pref("toolkit.telemetry.coverage.opt-out", true); // [HIDDEN PREF]
user_pref("toolkit.coverage.opt-out", true); // [FF64+] [HIDDEN PREF]
user_pref("toolkit.coverage.endpoint.base", "");
/* 0334: disable PingCentre telemetry (used in several System Add-ons) [FF57+]
 * Defense-in-depth: currently covered by 0331 ***/
user_pref("browser.ping-centre.telemetry", false);
/* 0335: disable Firefox Home (Activity Stream) telemetry ***/
user_pref("browser.newtabpage.activity-stream.feeds.telemetry", false);
user_pref("browser.newtabpage.activity-stream.telemetry", false);

/** STUDIES ***/
/* 0340: disable Studies
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to install and run studies ***/
user_pref("app.shield.optoutstudies.enabled", false);
/* 0341: disable Normandy/Shield [FF60+]
 * Shield is a telemetry system that can push and test "recipes"
 * [1] https://mozilla.github.io/normandy/ ***/
user_pref("app.normandy.enabled", false);
user_pref("app.normandy.api_url", "");

/** CRASH REPORTS ***/
/* 0350: disable Crash Reports ***/
user_pref("breakpad.reportURL", "");
user_pref("browser.tabs.crashReporting.sendReport", false); // [FF44+]
   // user_pref("browser.crashReports.unsubmittedCheck.enabled", false); // [FF51+] [DEFAULT: false]
/* 0351: enforce no submission of backlogged Crash Reports [FF58+]
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to send backlogged crash reports  ***/
user_pref("browser.crashReports.unsubmittedCheck.autoSubmit2", false); // [DEFAULT: false]

/** OTHER ***/
/* 0360: disable Captive Portal detection
 * [1] https://www.eff.org/deeplinks/2017/08/how-captive-portals-interfere-wireless-security-and-privacy ***/
user_pref("captivedetect.canonicalURL", "");
user_pref("network.captive-portal-service.enabled", false); // [FF52+]
/* 0361: disable Network Connectivity checks [FF65+]
 * [1] https://bugzilla.mozilla.org/1460537 ***/
user_pref("network.connectivity-service.enabled", false);

/*** [SECTION 0400]: SAFE BROWSING (SB)
   SB has taken many steps to preserve privacy. If required, a full url is never sent
   to Google, only a part-hash of the prefix, hidden with noise of other real part-hashes.
   Firefox takes measures such as stripping out identifying parameters and since SBv4 (FF57+)
   doesn't even use cookies. (#Turn on browser.safebrowsing.debug to monitor this activity)

   [1] https://feeding.cloud.geek.nz/posts/how-safe-browsing-works-in-firefox/
   [2] https://wiki.mozilla.org/Security/Safe_Browsing
   [3] https://support.mozilla.org/kb/how-does-phishing-and-malware-protection-work
   [4] https://educatedguesswork.org/posts/safe-browsing-privacy/
***/
user_pref("_user.js.parrot", "0400 syntax error: the parrot's passed on!");
/* 0401: disable SB (Safe Browsing)
 * [WARNING] Do this at your own risk! These are the master switches
 * [SETTING] Privacy & Security>Security>... Block dangerous and deceptive content ***/
   // user_pref("browser.safebrowsing.malware.enabled", false);
   // user_pref("browser.safebrowsing.phishing.enabled", false);
/* 0402: disable SB checks for downloads (both local lookups + remote)
 * This is the master switch for the safebrowsing.downloads* prefs (0403, 0404)
 * [SETTING] Privacy & Security>Security>... "Block dangerous downloads" ***/
   // user_pref("browser.safebrowsing.downloads.enabled", false);
/* 0403: disable SB checks for downloads (remote)
 * To verify the safety of certain executable files, Firefox may submit some information about the
 * file, including the name, origin, size and a cryptographic hash of the contents, to the Google
 * Safe Browsing service which helps Firefox determine whether or not the file should be blocked
 * [SETUP-SECURITY] If you do not understand this, or you want this protection, then override this ***/
user_pref("browser.safebrowsing.downloads.remote.enabled", false);
   // user_pref("browser.safebrowsing.downloads.remote.url", ""); // Defense-in-depth
/* 0404: disable SB checks for unwanted software
 * [SETTING] Privacy & Security>Security>... "Warn you about unwanted and uncommon software" ***/
   // user_pref("browser.safebrowsing.downloads.remote.block_potentially_unwanted", false);
   // user_pref("browser.safebrowsing.downloads.remote.block_uncommon", false);
/* 0405: disable "ignore this warning" on SB warnings [FF45+]
 * If clicked, it bypasses the block for that session. This is a means for admins to enforce SB
 * [TEST] see https://github.com/arkenfox/user.js/wiki/Appendix-A-Test-Sites#-mozilla
 * [1] https://bugzilla.mozilla.org/1226490 ***/
   // user_pref("browser.safebrowsing.allowOverride", false);
 
@toi la gay :sosad: phiền bác chút, cái Floorp em copy profile của FF tete sang đang bị cái "Open previous windows and tabs" nó vẫn mở lại những tab mà em đã đóng từ session trước nên giờ khá là loạn. Mở profile mới thì không thấy bị, bác có bắt bệnh được không?
 
@toi la gay :sosad: phiền bác chút, cái Floorp em copy profile của FF tete sang đang bị cái "Open previous windows and tabs" nó vẫn mở lại những tab mà em đã đóng từ session trước nên giờ khá là loạn. Mở profile mới thì không thấy bị, bác có bắt bệnh được không?
Thực ra mình chưa hình dung ra lỗi, chắc cần ảnh cơ mà vào folder profile rồi đổi tên folder sessionstore-backups thành sessionstore-backups_ xem sao, nếu có file sessionstore.jsonlz4 cũng đổi tên luôn thành sessionstore_.jsonlz4.
 
Hôm nay có nhắc tới vụ tạo Template cho PWA, sau một thời gian hỏi han tìm hiểu mình đã ngộ ra được chân lý nên phải viết ngay.

Ví dụ là ép cho PWA tiết kiệm RAM bằng cách tắt Fission đi nha.
  • Tạo một folder rỗng ở đâu thì tùy, ví dụ pwat
  • Tạo một file user.js trong thư mục trên, copy toàn bộ đoạn dưới vào:
Code:
user_pref("fission.autostart", false);
user_pref("dom.ipc.processCount", 1);
  • Save lại
  • Từ cửa sổ Firefox/Floorp, ấn vào biểu tượng PWA
  • Ấn vào cái bánh răng
  • Dán đường dẫn tới thư mục pwat vừa tạo ban nãy:
View attachment 2047205

Và thế là xong, từ nay mỗi khi bạn tạo một ứng dụng PWA mới, nó sẽ thừa hưởng file user.js và tắt Fission đi tiết kiệm rất nhiều RAM, các bạn có thể tham khảo #2 phần Tối ưu Firefox mình có để rất nhiều tối ưu, hoàn toàn có thể áp dụng một số tối ưu để tăng tốc PWA lên được như nglayout, tắt chạy nền, ví dụ đây là một file user.js hịn tắt Fission, tối ưu nglayout, tắt chạy nền:
Code:
user_pref("fission.autostart", false);
user_pref("dom.ipc.processCount", 1);
user_pref("nglayout.initialpaint.delay", 2000);
user_pref("nglayout.initialpaint.delay_in_oopif", 2000);
// Enable Multi-Account Container
user_pref("privacy.userContext.enabled", true); //enable Multi-Account Container
user_pref("privacy.userContext.ui.enabled", true); //enable Multi-Account Container

/*** [SECTION 0200]: GEOLOCATION / LANGUAGE / LOCALE ***/
user_pref("_user.js.parrot", "0200 syntax error: the parrot's definitely deceased!");
/* 0201: use Mozilla geolocation service instead of Google if permission is granted [FF74+]
 * Optionally enable logging to the console (defaults to false) ***/
user_pref("geo.provider.network.url", "https://location.services.mozilla.com/v1/geolocate?key=%MOZILLA_API_KEY%");
   // user_pref("geo.provider.network.logging.enabled", true); // [HIDDEN PREF]
/* 0202: disable using the OS's geolocation service ***/
user_pref("geo.provider.ms-windows-location", false); // [WINDOWS]
user_pref("geo.provider.use_corelocation", false); // [MAC]
user_pref("geo.provider.use_gpsd", false); // [LINUX]
user_pref("geo.provider.use_geoclue", false); // [FF102+] [LINUX]

/*** [SECTION 0300]: QUIETER FOX ***/
user_pref("_user.js.parrot", "0300 syntax error: the parrot's not pinin' for the fjords!");
/** RECOMMENDATIONS ***/
/* 0320: disable recommendation pane in about:addons (uses Google Analytics) ***/
user_pref("extensions.getAddons.showPane", false); // [HIDDEN PREF]
/* 0321: disable recommendations in about:addons' Extensions and Themes panes [FF68+] ***/
user_pref("extensions.htmlaboutaddons.recommendations.enabled", false);
/* 0322: disable personalized Extension Recommendations in about:addons and AMO [FF65+]
 * [NOTE] This pref has no effect when Health Reports (0331) are disabled
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to make personalized extension recommendations
 * [1] https://support.mozilla.org/kb/personalized-extension-recommendations ***/
user_pref("browser.discovery.enabled", false);

/** TELEMETRY ***/
/* 0330: disable new data submission [FF41+]
 * If disabled, no policy is shown or upload takes place, ever
 * [1] https://bugzilla.mozilla.org/1195552 ***/
user_pref("datareporting.policy.dataSubmissionEnabled", false);
/* 0331: disable Health Reports
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to send technical... data ***/
user_pref("datareporting.healthreport.uploadEnabled", false);
/* 0332: disable telemetry
 * The "unified" pref affects the behavior of the "enabled" pref
 * - If "unified" is false then "enabled" controls the telemetry module
 * - If "unified" is true then "enabled" only controls whether to record extended data
 * [NOTE] "toolkit.telemetry.enabled" is now LOCKED to reflect prerelease (true) or release builds (false) [2]
 * [1] https://firefox-source-docs.mozilla.org/toolkit/components/telemetry/telemetry/internals/preferences.html
 * [2] https://medium.com/georg-fritzsche/data-preference-changes-in-firefox-58-2d5df9c428b5 ***/
user_pref("toolkit.telemetry.unified", false);
user_pref("toolkit.telemetry.enabled", false); // see [NOTE]
user_pref("toolkit.telemetry.server", "data:,");
user_pref("toolkit.telemetry.archive.enabled", false);
user_pref("toolkit.telemetry.newProfilePing.enabled", false); // [FF55+]
user_pref("toolkit.telemetry.shutdownPingSender.enabled", false); // [FF55+]
user_pref("toolkit.telemetry.updatePing.enabled", false); // [FF56+]
user_pref("toolkit.telemetry.bhrPing.enabled", false); // [FF57+] Background Hang Reporter
user_pref("toolkit.telemetry.firstShutdownPing.enabled", false); // [FF57+]
/* 0333: disable Telemetry Coverage
 * [1] https://blog.mozilla.org/data/2018/08/20/effectively-measuring-search-in-firefox/ ***/
user_pref("toolkit.telemetry.coverage.opt-out", true); // [HIDDEN PREF]
user_pref("toolkit.coverage.opt-out", true); // [FF64+] [HIDDEN PREF]
user_pref("toolkit.coverage.endpoint.base", "");
/* 0334: disable PingCentre telemetry (used in several System Add-ons) [FF57+]
 * Defense-in-depth: currently covered by 0331 ***/
user_pref("browser.ping-centre.telemetry", false);
/* 0335: disable Firefox Home (Activity Stream) telemetry ***/
user_pref("browser.newtabpage.activity-stream.feeds.telemetry", false);
user_pref("browser.newtabpage.activity-stream.telemetry", false);

/** STUDIES ***/
/* 0340: disable Studies
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to install and run studies ***/
user_pref("app.shield.optoutstudies.enabled", false);
/* 0341: disable Normandy/Shield [FF60+]
 * Shield is a telemetry system that can push and test "recipes"
 * [1] https://mozilla.github.io/normandy/ ***/
user_pref("app.normandy.enabled", false);
user_pref("app.normandy.api_url", "");

/** CRASH REPORTS ***/
/* 0350: disable Crash Reports ***/
user_pref("breakpad.reportURL", "");
user_pref("browser.tabs.crashReporting.sendReport", false); // [FF44+]
   // user_pref("browser.crashReports.unsubmittedCheck.enabled", false); // [FF51+] [DEFAULT: false]
/* 0351: enforce no submission of backlogged Crash Reports [FF58+]
 * [SETTING] Privacy & Security>Firefox Data Collection & Use>Allow Firefox to send backlogged crash reports  ***/
user_pref("browser.crashReports.unsubmittedCheck.autoSubmit2", false); // [DEFAULT: false]

/** OTHER ***/
/* 0360: disable Captive Portal detection
 * [1] https://www.eff.org/deeplinks/2017/08/how-captive-portals-interfere-wireless-security-and-privacy ***/
user_pref("captivedetect.canonicalURL", "");
user_pref("network.captive-portal-service.enabled", false); // [FF52+]
/* 0361: disable Network Connectivity checks [FF65+]
 * [1] https://bugzilla.mozilla.org/1460537 ***/
user_pref("network.connectivity-service.enabled", false);

/*** [SECTION 0400]: SAFE BROWSING (SB)
   SB has taken many steps to preserve privacy. If required, a full url is never sent
   to Google, only a part-hash of the prefix, hidden with noise of other real part-hashes.
   Firefox takes measures such as stripping out identifying parameters and since SBv4 (FF57+)
   doesn't even use cookies. (#Turn on browser.safebrowsing.debug to monitor this activity)

   [1] https://feeding.cloud.geek.nz/posts/how-safe-browsing-works-in-firefox/
   [2] https://wiki.mozilla.org/Security/Safe_Browsing
   [3] https://support.mozilla.org/kb/how-does-phishing-and-malware-protection-work
   [4] https://educatedguesswork.org/posts/safe-browsing-privacy/
***/
user_pref("_user.js.parrot", "0400 syntax error: the parrot's passed on!");
/* 0401: disable SB (Safe Browsing)
 * [WARNING] Do this at your own risk! These are the master switches
 * [SETTING] Privacy & Security>Security>... Block dangerous and deceptive content ***/
   // user_pref("browser.safebrowsing.malware.enabled", false);
   // user_pref("browser.safebrowsing.phishing.enabled", false);
/* 0402: disable SB checks for downloads (both local lookups + remote)
 * This is the master switch for the safebrowsing.downloads* prefs (0403, 0404)
 * [SETTING] Privacy & Security>Security>... "Block dangerous downloads" ***/
   // user_pref("browser.safebrowsing.downloads.enabled", false);
/* 0403: disable SB checks for downloads (remote)
 * To verify the safety of certain executable files, Firefox may submit some information about the
 * file, including the name, origin, size and a cryptographic hash of the contents, to the Google
 * Safe Browsing service which helps Firefox determine whether or not the file should be blocked
 * [SETUP-SECURITY] If you do not understand this, or you want this protection, then override this ***/
user_pref("browser.safebrowsing.downloads.remote.enabled", false);
   // user_pref("browser.safebrowsing.downloads.remote.url", ""); // Defense-in-depth
/* 0404: disable SB checks for unwanted software
 * [SETTING] Privacy & Security>Security>... "Warn you about unwanted and uncommon software" ***/
   // user_pref("browser.safebrowsing.downloads.remote.block_potentially_unwanted", false);
   // user_pref("browser.safebrowsing.downloads.remote.block_uncommon", false);
/* 0405: disable "ignore this warning" on SB warnings [FF45+]
 * If clicked, it bypasses the block for that session. This is a means for admins to enforce SB
 * [TEST] see https://github.com/arkenfox/user.js/wiki/Appendix-A-Test-Sites#-mozilla
 * [1] https://bugzilla.mozilla.org/1226490 ***/
   // user_pref("browser.safebrowsing.allowOverride", false);
Chất lượng thật sự :beauty:
 
iMacro cũng chết rồi, mà ngày xưa mình dùng hồi Firefox còn giao diện vuông cai iMacro nó cho loop cả tỉ lần cũng không sao, không ngờ rằng sau này nó hóa thành scamware như ngày nay, giải pháp là sử dụng addon khác hay sửa mã nguồn của nó để bỏ giới hạn. Cơ mà để thực sự có một addon ngon hơn nó là rất khó, nên bỏ thời gian ra chỉnh lại source của nó vì dù sao nó cũng ngưng phát triển rồi, mình thích sửa sao thì sửa chứ quan tâm gì ba cái bản quyền nữa.

Để khi rảnh mình tìm cách sửa lại iMacro xem sao, chắc cũng chả khó lắm đâu, giải nén file xpi sang zip rồi lấu Notepad++ search all files in folder rồi tim 100 để tìm ra dòng giới hạn rồi tăng lên 10000000000000

Ngoài ra còn một cái mà làm được tất cả những thứ iMacros có thể làm và hơn thế là Selenium, nếu bạn rành lập trình thì cái này hoàn toàn có thể thay thế iMacros.

Đang thử bẻ khóa cái iMacros, cập nhập tiến độ, tài file xpi https://addons.mozilla.org/firefox/downloads/file/3766902/imacros_for_firefox-10.1.0.1485.xpi giải nén bằng cách đổi đuôi sang zip, cái này trong file mplayer.js:

Code:
MacroPlayer.prototype.checkFreewareLimits = function(type, value) {
    let check = (max, msg) => {
        if (value <= max) {
            return value
        } else {
            throw new FreewareLimit(msg + " " + value + " exceeds max value " + max)
        }
    }
    if(!this.limits)
        return value;
    switch(type) {
    case "lines":
        return check(this.limits.maxMacroLen, "macro length")
    case "loops":
        return check(this.limits.maxIterations, "number of iterations")
    case "csv_rows":
        return check(this.limits.maxCSVRows, "number of CSV rows")
    case "csv_cols":
        return check(this.limits.maxCSVCols, "number of CSV columns")
    case "user_vars":
        if (!this.limits.userVars) {
            throw new FreewareLimit("user defined variables not allowed."+
                                    " Maximum number of variables is " +
                                    this.limits.maxVariables)
        } else {
            return value
        }
    }
}

Sửa lại thử xem:

Code:
MacroPlayer.prototype.checkFreewareLimits = function(type, value) {
    let check = (max, msg) => {
        if (value <= 9999999999999999999999999999999999999999999999) {
            return value
        } else {
            throw new FreewareLimit(msg + " " + value + " exceeds max value " + max)
        }
    }
    if(!this.limits)
        return value;
    switch(type) {
    case "lines":
        return check(this.limits.maxMacroLen, "macro length")
    case "loops":
        return check(this.limits.maxIterations, "number of iterations")
    case "csv_rows":
        return check(this.limits.maxCSVRows, "number of CSV rows")
    case "csv_cols":
        return check(this.limits.maxCSVCols, "number of CSV columns")
    case "user_vars":
        if (!this.limits.userVars) {
            throw new FreewareLimit("user defined variables not allowed."+
                                    " Maximum number of variables is " +
                                    this.limits.maxVariables)
        } else {
            return value
        }
    }
}

Thế là xong đó, giờ có thể loop tối đa 9999999999999999999999999999999999999999999999 lần.

Hoặc có thể bỏ tất cả giới hạn và biến nó thành bản Pro/Enterprise luôn, thay bằng:

Code:
MacroPlayer.prototype.checkFreewareLimits = function(type, value) {
    return value;
}

Giờ nén lại rồi chuyển qua xpi và ném vào Firefox rồi cài. https://stackoverflow.com/questions/19240653/how-to-create-xpi-file-with-7zip

Hậu quả ?
Link tải https://www.sendspace.com/file/fpc9ax

Vãi chưởng 10 năm rồi không code addon Firefox, may mà vẫn còn nhớ mang máng vài thủ thuật :LOL:
bạn có thể cho mình xin file đã chỉnh sửa? mình làm theo mà cài đặt bị bsáo lỗi
 
"Flop" của mình từ khi lên bản 11.2 mất hàng phút để thoát hẳn trình duyệt, nhưng mở thì vẫn nhanh. Các bác có cao kiến gì không? :ah:
Bọn đồng phạm:
user_pref("browser.sessionstore.enabled", false);
user_pref("browser.sessionstore.idleDelay", -1);
user_pref("browser.sessionstore.interval", -1);
user_pref("browser.sessionstore.interval.idle", -1);
user_pref("browser.sessionstore.max_resumed_crashes", 0);
user_pref("browser.sessionstore.resume_from_crash", false);
user_pref("browser.sessionstore.upgradeBackup.maxUpgradeBackups", 0);
user_pref("browser.startup.page", 0);
Nếu chỉnh browser.startup.page = 3 thì shutdown lại nhanh nhưng thanh bookmark trống trơn :LOL:, phải đưa browser.sessionstore.idleDelay về mặc định mới hiện các bookmark :LOL:.

Thật kỳ quặc :confused:.
 
bạn có thể cho mình xin file đã chỉnh sửa? mình làm theo mà cài đặt bị bsáo lỗi
Addon này cũ rồi mình có để link tải trong thread tuy nhiên cũng vì nó cũ nên mình không cho vào chỉ mục tra cứu vì kiểu gì nó cũng lỗi càng lỗi sau này nên có gì bạn chịu khó dùng search tìm trong thread này và bạn cần sử dụng Firefox Nightly hoặc mod Tete/Floorp mới cài được không sẽ báo lỗi, tuy nhiên bạn nên xài UI.vision vì nó dễ dùng hơn tất cả thao tác đều là đồ họa hết không phải code.

Ngoài ra còn Automa được giới thiệu bởi @shenzero999 : https://voz.vn/t/tong-hop-nhung-addon-chat-cho-firefox-pc-mobile.682181/post-26815688
 
@toi la gay :sosad: khi nào thì nên chỉnh trong about:config, khi nào trong prefs.js, khi nào trong user.js fen?
Nếu chỉnh cả 3 chỗ luôn thì firefox xử lý như nào?
  • prefs.jsabout:config là một, sửa cái nào cũng như nhau cơ mà người dùng bình thường chỉ nên dùng about:config thôi, vì prefs.js phải tắt Firefox đi nó mới ăn nhé vì Firefox luôn luôn ghi file này cứ vài s một lần nên chỉnh xong không tắt sẽ bị ghi đè
  • user.js dùng cho trường hợp muốn khóa một config lại khi dùng nhiều trình duyệt hoặc để chia sẻ giữa nhiều máy khác nhau tạo Template, cứ hiểu là tốn cả buổi chỉnh sửa thì nếu làm tất trong user.js thì chỉ cần backup file này sau này cài lại máy do bị dính virus tống tình thì dùng file này khôi phục lại tất, xem ví dụ: https://voz.vn/t/tong-hop-nhung-addon-chat-cho-firefox-pc-mobile.682181/post-27487680
  • user.js luôn có quyền cao nhất, chỉnh đâu thì chính user.js luôn ghi đè
  • Nếu rành thì sau khi chỉnh sửa xong có thể chiết xuất từ prefs.js ra sau này tái sử dụng
 
Bọn đồng phạm:

Nếu chỉnh browser.startup.page = 3 thì shutdown lại nhanh nhưng thanh bookmark trống trơn :LOL:, phải đưa browser.sessionstore.idleDelay về mặc định mới hiện các bookmark :LOL:.

Thật kỳ quặc :confused:.
Nghịch vãi, mấy cái session này nghịch cẩn thận tránh xa các khóa này ra kẻo hỏng luôn file session vì trước mình chuột bạch rồi:
browser.sessionstore.platform_collectiontrue

Chỉ các khóa này là an toàn:
Giảm ghi session cứ mỗi milisecond:
browser.sessionstore.interval3600000

Ép tab đã pin cũng phải unload khi phục hồi:
browser.sessionstore.restore_pinned_tabs_on_demandtrue

Tắt thu thập zoom, giảm dung lượng session:
browser.sessionstore.collect_zoomfalse

Giảm bớt chi tiết khi lưu session, tương tự:
 
  • prefs.jsabout:config là một, sửa cái nào cũng như nhau cơ mà người dùng bình thường chỉ nên dùng about:config thôi, vì prefs.js phải tắt Firefox đi nó mới ăn nhé vì Firefox luôn luôn ghi file này cứ vài s một lần nên chỉnh xong không tắt sẽ bị ghi đè
  • user.js dùng cho trường hợp muốn khóa một config lại khi dùng nhiều trình duyệt hoặc để chia sẻ giữa nhiều máy khác nhau tạo Template, cứ hiểu là tốn cả buổi chỉnh sửa thì nếu làm tất trong user.js thì chỉ cần backup file này sau này cài lại máy do bị dính virus tống tình thì dùng file này khôi phục lại tất, xem ví dụ: https://voz.vn/t/tong-hop-nhung-addon-chat-cho-firefox-pc-mobile.682181/post-27487680
  • user.js luôn có quyền cao nhất, chỉnh đâu thì chính user.js luôn ghi đè
  • Nếu rành thì sau khi chỉnh sửa xong có thể chiết xuất từ prefs.js ra sau này tái sử dụng
nếu thêm 1 config trong user.js xong, rồi bật firefox lên, sau đó tắt firefox và xóa config vừa thêm trong user.js thì firefox còn lưu config đó ko fen?
 
Dùng file bat này nó sẽ khôi phục lại prefs.js dựa trên nội dung của user.js, nghĩa là tất cả những gì đã thêm vào prefs.js từ user.js sẽ bị xóa sạch:

Đặt chung vào folder profile chứa cả hai file trên user.jsprefs.js:
https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/prefsCleaner.bat
Bác cho m hỏi chút nhỉ. Cái đưa cache lên ram ấy, nếu nó tốt vậy thì sao ng ta k mặc định như vậy đi. Nó phải có nhược điểm gì chứ bác?. Hay ng ta sợ ram ng dùng bé?
 
Back
Top