浏览代码

added toString methods

Gildas 7 年之前
父节点
当前提交
0410d4ba08
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      lib/hooks/hooks-frame.js

+ 2 - 0
lib/hooks/hooks-frame.js

@@ -266,6 +266,7 @@ this.hooksFrame = this.hooksFrame || (() => {
 				}
 				return new FontFace(...arguments);
 			};
+			window.FontFace.toString = function () { return "function FontFace() { [native code]"; };
 		}
 
 		if (window.IntersectionObserver) {
@@ -305,6 +306,7 @@ this.hooksFrame = this.hooksFrame || (() => {
 				observers.set(intersectionObserver, { callback, options });
 				return intersectionObserver;
 			};
+			window.IntersectionObserver.toString = function () { return "function IntersectionObserver() { [native code]"; };
 		}
 	}