MemeFI web

Running TapSwap in a browser

此脚本不应直接安装,它是一个供其他脚本使用的外部库。如果您需要使用该库,请在脚本元属性加入:// @require https://update.gf.qytechs.cn/scripts/511452/1459040/MemeFI%20web.js

  1. // ==UserScript==
  2. // @name MemeFI web
  3. // @version 1.0
  4. // @description Running TapSwap in a browser
  5. // @author amir-homous
  6. // @match https://tg-app.memefi.club/*
  7. // @grant none
  8. // @icon https://s2.coinmarketcap.com/static/img/coins/64x64/29373.png
  9. // @downloadURL https://github.com/amir-homous/MemeFi-Coin/raw/main/memefi-web.user.js
  10. // @updateURL https://github.com/amir-homous/MemeFi-Coin/raw/main/memefi-web.user.js
  11. // @homepage https://github.com/amir-homous/MemeFi-Coin
  12. // ==/UserScript==
  13.  
  14. (function() {
  15. 'use strict';
  16.  
  17. const originalUrl = 'https://telegram.org/js/telegram-web-app.js';
  18. const newUrl = 'https://ktnff.tech/universal/telegram-web-app.js';
  19.  
  20. // Create a MutationObserver to watch for script tags being added to the DOM
  21. const observer = new MutationObserver((mutations) => {
  22. mutations.forEach((mutation) => {
  23. mutation.addedNodes.forEach((node) => {
  24. if (node.tagName === 'SCRIPT' && node.src === originalUrl) {
  25. node.src = newUrl;
  26. }
  27. });
  28. });
  29. });
  30.  
  31. // Start observing the document for script tags being added
  32. observer.observe(document.documentElement, { childList: true, subtree: true });
  33.  
  34. // Override the appendChild method to replace the script URL
  35. const originalAppendChild = Node.prototype.appendChild;
  36. Node.prototype.appendChild = function(child) {
  37. if (child.tagName === 'SCRIPT' && child.src === originalUrl) {
  38. child.src = newUrl;
  39. }
  40. return originalAppendChild.call(this, child);
  41. };
  42.  
  43. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址