Hardware Acceleration and Web Performance Enhancer

Toggle hardware acceleration and enhance web performance

当前为 2024-08-30 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Hardware Acceleration and Web Performance Enhancer
  3. // @namespace http://tampermonkey.net/
  4. // @version 0.5
  5. // @description Toggle hardware acceleration and enhance web performance
  6. // @author Tae
  7. // @match *://*/*
  8. // @grant none
  9. // @license MIT
  10. // ==/UserScript==
  11.  
  12. (function() {
  13. 'use strict';
  14.  
  15. // Load Quicklink
  16. const script = document.createElement('script');
  17. script.src = 'https://unpkg.com/quicklink@2.0.0/dist/quicklink.umd.js';
  18. script.onload = () => quicklink.listen({
  19. origins: true, // Only prefetch links from the same origin
  20. ignores: [ // Ignore links that might cause issues
  21. (uri) => uri.includes('logout'),
  22. (uri) => uri.includes('login'),
  23. (uri) => uri.includes('account')
  24. ]
  25. });
  26. document.head.appendChild(script);
  27. })();