Fake random.org

Fake ranndom.org result

当前为 2023-09-29 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Fake random.org
  3. // @version 0.1
  4. // @description Fake ranndom.org result
  5. // @namespace gist.github.com/nghiepdev/5cab09f3edb35c4a17af2453fb01a852
  6. // @author nghiepdev
  7. // @match https://www.random.org/widgets/integers/iframe?*
  8. // @icon https://www.google.com/s2/favicons?sz=64&domain=random.org
  9. // @grant none
  10. // @license GPLv3
  11. // ==/UserScript==
  12.  
  13. (function() {
  14. 'use strict';
  15. const RESULT = 13;
  16. const originalReplaceAll = window.replaceAll;
  17. window.replaceAll = (a, b, c) => {
  18. const result = originalReplaceAll(a, b, c);
  19. return result.replace(/\d+(?=\<br)/, RESULT);
  20. };
  21. })();