Greasy Fork is available in English.

Chống rút gọn Traffic1s.com

Không cần tìm code trên google

  1. // ==UserScript==
  2. // @name Traffic1s.com skipper
  3. // @name:vi Chống rút gọn Traffic1s.com
  4. // @namespace SignedBy.hUwUtao
  5. // @license MIT
  6. // @version 0.1
  7. // @description time is golden, not for ya
  8. // @description:vi Không cần tìm code trên google
  9. // @author hUwUtao
  10. // @match https://traffic1s.com/*
  11. // ==/UserScript==
  12. document.getElementsByName("code").length != 0 && //
  13. (!new URLSearchParams(window.location.search).get("code") || //
  14. document.querySelector(".alert.alert-danger") != null) && //
  15. ((host) =>
  16. fetch("https://traffic1s.com/get-code?hostname=" + host)
  17. .then((response) => response.json())
  18. .then(
  19. (response) =>
  20. (window.location.href = (function (c) {
  21. const u = new URL(window.location.href);
  22. u.searchParams.set("code", c);
  23. return u.toString();
  24. })(response.html))
  25. ))(prompt("Type in the hostname of requested page: ex google.com"));