From 33058f2b292b3a581333bdfb21b8f671898c5060 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:40:17 -0500 Subject: initial commit --- .../global_objects/function/tosource/index.html | 49 ++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 files/zh-cn/web/javascript/reference/global_objects/function/tosource/index.html (limited to 'files/zh-cn/web/javascript/reference/global_objects/function/tosource') diff --git a/files/zh-cn/web/javascript/reference/global_objects/function/tosource/index.html b/files/zh-cn/web/javascript/reference/global_objects/function/tosource/index.html new file mode 100644 index 0000000000..5c4de38138 --- /dev/null +++ b/files/zh-cn/web/javascript/reference/global_objects/function/tosource/index.html @@ -0,0 +1,49 @@ +--- +title: Function.prototype.toSource() +slug: Web/JavaScript/Reference/Global_Objects/Function/toSource +translation_of: Web/JavaScript/Reference/Global_Objects/Function/toSource +--- +
+
{{JSRef("Global_Objects", "Function")}} {{non-standard_header}}
+
+ +

概述

+ +

返回函数的源代码的字符串表示.

+ +

语法

+ +
function.toSource();
+Function.toSource();
+
+ +

参数

+ +

+ +

描述

+ +

toSource方法返回下面的值:

+ +

+ + + +
function Function() {
+    [native code]
+}
+ + + +

该方法通常在引擎内部调用.你可以在调试的时候用该方法开查看一个函数的源代码.

+ +

相关链接

+ + -- cgit v1.2.3-54-g00ecf