Chrome Cache Cleaner

Clears Chrome's cache

  1. // ==UserScript==
  2. // @name Chrome Cache Cleaner
  3. // @namespace tampermonkey
  4. // @version 1.1
  5. // @description Clears Chrome's cache
  6. // @author [Your Name]
  7. // @match *://*/*
  8. // @icon    https://w7.pngwing.com/pngs/968/191/png-transparent-google-chrome-web-browser-chrome-web-store-chrome-os-chromebook-google-logo-sphere-window-thumbnail.png
  9. // ==/UserScript==
  10.  
  11. (function() {
  12. 'use strict';
  13.  
  14. // キャッシュクリアを実行
  15. chrome.browsingData.fetchDataStorageCache([
  16. {
  17. origin: 'https://' + window.location.hostname,
  18. storageType: 'cache'
  19. }
  20. ], function(bytes) {
  21. console.log('Cleared ' + bytes + ' bytes of cache.');
  22. });
  23. })();